X-Git-Url: https://git.mxchange.org/?a=blobdiff_plain;ds=sidebyside;f=mod%2Fmatch.php;h=69bf3c1101142f33bdd98c3ef40669d12f0d46c5;hb=a9bed1422e0a476df17a9e6edefce1925404184d;hp=3b0367b4290e1efd02ccbd945eca34fb4e79bb4d;hpb=226bda9f58254bf2b77cd5e323385537f6dfe25f;p=friendica.git diff --git a/mod/match.php b/mod/match.php index 3b0367b429..69bf3c1101 100644 --- a/mod/match.php +++ b/mod/match.php @@ -27,8 +27,9 @@ function match_content(&$a) { $r = q("SELECT `pub_keywords`, `prv_keywords` FROM `profile` WHERE `is-default` = 1 AND `uid` = %d LIMIT 1", intval(local_user()) ); - if(! count($r)) + if (! dbm::is_result($r)) { return; + } if(! $r[0]['pub_keywords'] && (! $r[0]['prv_keywords'])) { notice( t('No keywords to match. Please add keywords to your default profile.') . EOL); return; @@ -67,8 +68,10 @@ function match_content(&$a) { if (!count($match)) { $jj->photo = str_replace("http:///photo/", get_server()."/photo/", $jj->photo); $connlnk = $a->get_baseurl() . '/follow/?url=' . $jj->url; - $photo_menu = array(array(t("View Profile"), zrl($jj->url))); - $photo_menu[] = array(t("Connect/Follow"), $connlnk); + $photo_menu = array( + 'profile' => array(t("View Profile"), zrl($jj->url)), + 'follow' => array(t("Connect/Follow"), $connlnk) + ); $contact_details = get_contact_details_by_url($jj->url, local_user()); @@ -79,7 +82,7 @@ function match_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), 'thumb' => proxy_url($jj->photo, false, PROXY_SIZE_THUMB), 'inttxt' => ' ' . t('is interested in:'), 'conntxt' => t('Connect'),