X-Git-Url: https://git.mxchange.org/?a=blobdiff_plain;f=src%2FCore%2FProtocol.php;h=015612adeaea1af9575727792f25b89ef41e965c;hb=87bb4d44a2eccec4180b9cd0a70f9011b3b759bc;hp=c141bbc54e6240f2c79372050468e458ab34964c;hpb=f36d4891bcf0a0eb4f0243851375966d6e99d201;p=friendica.git diff --git a/src/Core/Protocol.php b/src/Core/Protocol.php index c141bbc54e..015612adea 100644 --- a/src/Core/Protocol.php +++ b/src/Core/Protocol.php @@ -22,6 +22,7 @@ namespace Friendica\Core; use Friendica\Database\DBA; +use Friendica\Model\Item; use Friendica\Model\User; use Friendica\Network\HTTPException; use Friendica\Protocol\Activity; @@ -139,7 +140,7 @@ class Protocol // create a follow slap $item = [ 'verb' => Activity::FOLLOW, - 'gravity' => GRAVITY_ACTIVITY, + 'gravity' => Item::GRAVITY_ACTIVITY, 'follow' => $contact['url'], 'body' => '', 'title' => '', @@ -191,14 +192,16 @@ class Protocol if (in_array($protocol, [Protocol::OSTATUS, Protocol::DFRN])) { // create an unfollow slap - $item = []; - $item['verb'] = Activity::O_UNFOLLOW; - $item['gravity'] = GRAVITY_ACTIVITY; - $item['follow'] = $contact['url']; - $item['body'] = ''; - $item['title'] = ''; - $item['guid'] = ''; - $item['uri-id'] = 0; + $item = [ + 'verb' => Activity::O_UNFOLLOW, + 'gravity' => Item::GRAVITY_ACTIVITY, + 'follow' => $contact['url'], + 'body' => '', + 'title' => '', + 'guid' => '', + 'uri-id' => 0, + ]; + $slap = OStatus::salmon($item, $user); if (empty($contact['notify'])) {