]> git.mxchange.org Git - friendica.git/blobdiff - mod/unfollow.php
Merge pull request #10173 from annando/attach-speed
[friendica.git] / mod / unfollow.php
index 54e015cf5272a25f1de02672ca1475c76140cf37..1c6022a4cb4b31dce2420f33d078dd96a004cb65 100644 (file)
@@ -1,6 +1,6 @@
 <?php
 /**
- * @copyright Copyright (C) 2020, Friendica
+ * @copyright Copyright (C) 2010-2021, the Friendica project
  *
  * @license GNU AGPL version 3 or any later version
  *
@@ -59,7 +59,7 @@ function unfollow_content(App $a)
                local_user(), Contact::SHARING, Contact::FRIEND, Strings::normaliseLink($url),
                Strings::normaliseLink($url), $url];
 
-       $contact = DBA::selectFirst('contact', ['url', 'network', 'addr', 'name'], $condition);
+       $contact = DBA::selectFirst('contact', ['url', 'id', 'uid', 'network', 'addr', 'name'], $condition);
 
        if (!DBA::isResult($contact)) {
                notice(DI::l10n()->t("You aren't following this contact."));
@@ -99,7 +99,7 @@ function unfollow_content(App $a)
                '$submit'        => DI::l10n()->t('Submit Request'),
                '$cancel'        => DI::l10n()->t('Cancel'),
                '$url'           => $contact['url'],
-               '$zrl'           => Contact::magicLink($contact['url']),
+               '$zrl'           => Contact::magicLinkByContact($contact),
                '$url_label'     => DI::l10n()->t('Profile URL'),
                '$myaddr'        => $self['url'],
                '$request'       => $request,