]> git.mxchange.org Git - friendica.git/blobdiff - src/Model/Introduction.php
Added logging
[friendica.git] / src / Model / Introduction.php
index 8b939aa2a58def146def3905bcbbc523806b6776..aab4a9a8e47667857b74034671c446b9127a81f3 100644 (file)
@@ -164,19 +164,16 @@ class Introduction extends BaseModel
                }
 
                $contact = Contact::selectFirst([], ['id' => $this->{'contact-id'}, 'uid' => $this->uid]);
+               if (!empty($contact)) {
+                       if (!empty($contact['protocol'])) {
+                               $protocol = $contact['protocol'];
+                       } else {
+                               $protocol = $contact['network'];
+                       }
 
-               if (!$contact) {
-                       throw new HTTPException\NotFoundException('Contact record not found.');
-               }
-
-               if (!empty($contact['protocol'])) {
-                       $protocol = $contact['protocol'];
-               } else {
-                       $protocol = $contact['network'];
-               }
-
-               if ($protocol == Protocol::ACTIVITYPUB) {
-                       ActivityPub\Transmitter::sendContactReject($contact['url'], $contact['hub-verify'], $contact['uid']);
+                       if ($protocol == Protocol::ACTIVITYPUB) {
+                               ActivityPub\Transmitter::sendContactReject($contact['url'], $contact['hub-verify'], $contact['uid']);
+                       }
                }
 
                return $this->intro->delete($this);