Merge pull request #7752 from kPherox/develop
[friendica.git/.git] / src / Protocol / ActivityPub / Transmitter.php
index efadcbb..d2581ff 100644 (file)
@@ -547,6 +547,10 @@ class Transmitter
 
                $contacts = DBA::select('contact', ['url', 'network', 'protocol'], $condition);
                while ($contact = DBA::fetch($contacts)) {
+                       if (Contact::isLocal($contact['url'])) {
+                               continue;
+                       }
+
                        if (!in_array($contact['network'], $networks) && ($contact['protocol'] != Protocol::ACTIVITYPUB)) {
                                continue;
                        }
@@ -614,6 +618,10 @@ class Transmitter
                                if ($receiver == $item_profile['followers']) {
                                        $inboxes = array_merge($inboxes, self::fetchTargetInboxesforUser($uid, $personal));
                                } else {
+                                       if (Contact::isLocal($receiver)) {
+                                               continue;
+                                       }
+
                                        $profile = APContact::getByURL($receiver, false);
                                        if (!empty($profile)) {
                                                if (empty($profile['sharedinbox']) || $personal || $blindcopy) {