]> git.mxchange.org Git - friendica.git/blobdiff - src/Protocol/Activity.php
Reduce the amount of "UpdateContact" worker calls
[friendica.git] / src / Protocol / Activity.php
index e75b1cf507213b00919be6f7560f5a30453da15f..7212e919410fb2f236d65e6d1c1375743490436c 100644 (file)
@@ -163,15 +163,13 @@ final class Activity
         * @var string
         */
        const ANNOUNCE   = ActivityNamespace::ACTIVITY2 . 'Announce';
-
        /**
-        * Pokes an user.
+        * Indicates that the actor has read the object.
         *
-        * @see https://github.com/friendica/friendica/wiki/ActivityStreams#activity_poke
+        * @see https://www.w3.org/TR/activitystreams-vocabulary/#dfn-read
         * @var string
         */
-       const POKE       = ActivityNamespace::ZOT . '/activity/poke';
-
+       const READ       = ActivityNamespace::ACTIVITY2 . 'read';
 
        const O_UNFOLLOW    = ActivityNamespace::OSTATUS . '/unfollow';
        const O_UNFAVOURITE = ActivityNamespace::OSTATUS . '/unfavorite';
@@ -203,6 +201,7 @@ final class Activity
                self::ANNOUNCE,
                self::EMOJIREACT,
                self::VIEW,
+               self::READ,
        ];
 
        /**
@@ -212,7 +211,7 @@ final class Activity
         *
         * @return bool True, if the activity is hidden
         */
-       public function isHidden(string $activity)
+       public function isHidden(string $activity): bool
        {
                foreach (self::HIDDEN_ACTIVITIES as $hiddenActivity) {
                        if ($this->match($activity, $hiddenActivity)) {
@@ -231,7 +230,7 @@ final class Activity
         *
         * @return boolean
         */
-       public function match(string $haystack, string $needle)
+       public function match(string $haystack, string $needle): bool
        {
                return (($haystack === $needle) ||
                        ((basename($needle) === $haystack) &&