From: Hypolite Petovan Date: Fri, 23 Nov 2018 16:09:43 +0000 (-0500) Subject: Fix display of Connect/Disconnect links on contact page X-Git-Url: https://git.mxchange.org/?a=commitdiff_plain;h=4b8af105616803f2cf08a759a896184b60b23c09;p=friendica.git Fix display of Connect/Disconnect links on contact page --- diff --git a/src/Module/Contact.php b/src/Module/Contact.php index 80e9c73b63..ec7e896925 100644 --- a/src/Module/Contact.php +++ b/src/Module/Contact.php @@ -570,12 +570,12 @@ class Contact extends BaseModule /// @todo Only show the following link with DFRN when the remote version supports it $follow = ''; $follow_text = ''; - if (in_array($contact['rel'], [Model\Contact::FRIEND, Model\Contact::SHARING])) { + if ($contact['uid'] && in_array($contact['rel'], [Model\Contact::FRIEND, Model\Contact::SHARING])) { if (in_array($contact['network'], Protocol::NATIVE_SUPPORT)) { $follow = $a->getBaseURL(true) . '/unfollow?url=' . urlencode($contact['url']); $follow_text = L10n::t('Disconnect/Unfollow'); } - } else { + } elseif(!$contact['pending']) { $follow = $a->getBaseURL(true) . '/follow?url=' . urlencode($contact['url']); $follow_text = L10n::t('Connect/Follow'); }