]> git.mxchange.org Git - friendica.git/blobdiff - mod/allfriends.php
Continued with #3010:
[friendica.git] / mod / allfriends.php
index 360b222b50dd647ad56d0febaff70c75129bffda..240aa524be308ea605076fcb250a9da693a7dd42 100644 (file)
@@ -39,7 +39,7 @@ function allfriends_content(&$a) {
 
        $r = all_friends(local_user(), $cid, $a->pager['start'], $a->pager['itemspage']);
 
-       if(! count($r)) {
+       if(! dbm::is_result($r)) {
                $o .= t('No friends to display.');
                return $o;
        }
@@ -61,8 +61,10 @@ function allfriends_content(&$a) {
                }
                else {
                        $connlnk = $a->get_baseurl() . '/follow/?url=' . $rr['url'];
-                       $photo_menu = array(array(t("View Profile"), zrl($rr['url'])));
-                       $photo_menu[] = array(t("Connect/Follow"), $connlnk);
+                       $photo_menu = array(
+                               'profile' => array(t("View Profile"), zrl($rr['url'])),
+                               'follow' => array(t("Connect/Follow"), $connlnk)
+                       );
                }
 
                $entry = array(
@@ -74,7 +76,7 @@ function allfriends_content(&$a) {
                        'details'       => $contact_details['location'],
                        'tags'          => $contact_details['keywords'],
                        'about'         => $contact_details['about'],
-                       'account_type'  => (($contact_details['community']) ? t('Forum') : ''),
+                       'account_type'  => account_type($contact_details),
                        'network'       => network_to_name($contact_details['network'], $contact_details['url']),
                        'photo_menu'    => $photo_menu,
                        'conntxt'       => t('Connect'),