X-Git-Url: https://git.mxchange.org/?a=blobdiff_plain;f=include%2FForumManager.php;h=8473035affe43faf33440faa3479f22543c77584;hb=96501bda816bb3db29ea19d89e6ffc0e83f350b3;hp=cb353a9d9b99a9727acec2efdc6437da5772df07;hpb=e67554924accc40fc68b8c68c85a4db7fb1f73e5;p=friendica.git diff --git a/include/ForumManager.php b/include/ForumManager.php index cb353a9d9b..8473035aff 100644 --- a/include/ForumManager.php +++ b/include/ForumManager.php @@ -1,5 +1,8 @@ `failure_update` $order ", - intval($uid) + $uid ); if (!$contacts) return($forumlist); - foreach($contacts as $contact) { + while ($contact = dba::fetch($contacts)) { $forumlist[] = array( 'url' => $contact['url'], 'name' => $contact['name'], @@ -59,6 +62,8 @@ class ForumManager { 'thumb' => $contact['thumb'], ); } + dba::close($contacts); + return($forumlist); } @@ -88,7 +93,7 @@ class ForumManager { $total = count($contacts); $visible_forums = 10; - if(count($contacts)) { + if (dbm::is_result($contacts)) { $id = 0; @@ -102,7 +107,7 @@ class ForumManager { 'name' => $contact['name'], 'cid' => $contact['id'], 'selected' => $selected, - 'micro' => App::remove_baseurl(proxy_url($contact['micro'], false, PROXY_SIZE_MICRO)), + 'micro' => System::removedBaseUrl(proxy_url($contact['micro'], false, PROXY_SIZE_MICRO)), 'id' => ++$id, ); $entries[] = $entry;