X-Git-Url: https://git.mxchange.org/?a=blobdiff_plain;f=mod%2Fcommon.php;h=9781d1607c4f38011ff0e0e081912e63ca51406b;hb=de689583e2741a2caee0e266a19a07d1ad4ed043;hp=9b2c69f6d70c4955b12daaa6cca20ddf9e49f7de;hpb=2e9d233367068fceac8005126d14a2002539c772;p=friendica.git diff --git a/mod/common.php b/mod/common.php index 9b2c69f6d7..9781d1607c 100644 --- a/mod/common.php +++ b/mod/common.php @@ -57,13 +57,13 @@ function common_content(&$a) { dbesc(normalise_link(get_my_url())), intval($profile_uid) ); - if(count($r)) + if (dbm::is_result($r)) $cid = $r[0]['id']; else { $r = q("SELECT `id` FROM `gcontact` WHERE `nurl` = '%s' LIMIT 1", dbesc(normalise_link(get_my_url())) ); - if(count($r)) + if (dbm::is_result($r)) $zcid = $r[0]['id']; } } @@ -94,7 +94,7 @@ function common_content(&$a) { $r = common_friends_zcid($uid, $zcid, $a->pager['start'], $a->pager['itemspage']); - if(! count($r)) { + if (! dbm::is_result($r)) { return $o; } @@ -120,7 +120,7 @@ function common_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, 'id' => ++$id,