]> git.mxchange.org Git - friendica.git/commitdiff
Function renamed to better reflect the purpose
authorMichael <heluecht@pirati.ca>
Thu, 5 Mar 2020 08:03:05 +0000 (08:03 +0000)
committerMichael <heluecht@pirati.ca>
Thu, 5 Mar 2020 08:03:05 +0000 (08:03 +0000)
include/api.php
mod/subthread.php
src/Model/Item.php
src/Module/Like.php

index 3a29184ec777589a1778db08ce09e6894a845516..ef738891265260e160172de6c9cdf0740b20a854 100644 (file)
@@ -5823,7 +5823,7 @@ function api_friendica_activity($type)
 
        $id = $_REQUEST['id'] ?? 0;
 
-       $res = Item::performLike($id, $verb);
+       $res = Item::performActivity($id, $verb);
 
        if ($res) {
                if ($type == "xml") {
index 24b20d49dc6dca26c202def892fd5299b98f443a..ebec978c592c9300dcd883c4c68b6cec707e1b14 100644 (file)
@@ -34,7 +34,7 @@ function subthread_content(App $a)
 
        $item_id = (($a->argc > 1) ? Strings::escapeTags(trim($a->argv[1])) : 0);
 
-       if (!Item::performLike($item_id, 'follow')) {
+       if (!Item::performActivity($item_id, 'follow')) {
                Logger::info('Following item failed', ['item' => $item_id]);
                throw new HTTPException\BadRequestException();
        }
index 5a1e957db841f9cb3f62dfec609a5437a38ebefc..f3b27ac80f8600251eaf233cbbb24c109784d8ed 100644 (file)
@@ -3141,7 +3141,7 @@ class Item
         *            array $arr
         *            'post_id' => ID of posted item
         */
-       public static function performLike($item_id, $verb)
+       public static function performActivity($item_id, $verb)
        {
                if (!Session::isAuthenticated()) {
                        return false;
index a85044714f582f77718d1ab7b937585f88094762..c926012f18d7687c60fc21e07888dd9953bf3641 100644 (file)
@@ -50,7 +50,7 @@ class Like extends BaseModule
                // @TODO: Replace with parameter from router
                $itemId = (($app->argc > 1) ? Strings::escapeTags(trim($app->argv[1])) : 0);
 
-               if (!Item::performLike($itemId, $verb)) {
+               if (!Item::performActivity($itemId, $verb)) {
                        throw new HTTPException\BadRequestException();
                }