]> git.mxchange.org Git - friendica.git/commitdiff
Merge pull request #5700 from annando/issue-5653
authorHypolite Petovan <mrpetovan@eml.cc>
Thu, 30 Aug 2018 00:17:15 +0000 (20:17 -0400)
committerGitHub <noreply@github.com>
Thu, 30 Aug 2018 00:17:15 +0000 (20:17 -0400)
Issue 5653: The mastodonemoji addon hadn't got all needed data.

src/Model/Item.php

index d235f0a7f96bab562745c0be47b04c5131b8e5e5..d10a211a59511d98b579583d748c2ff004471a4f 100644 (file)
@@ -1462,15 +1462,6 @@ class Item extends BaseObject
                        return 0;
                }
 
-               // These fields aren't stored anymore in the item table, they are fetched upon request
-               unset($item['author-link']);
-               unset($item['author-name']);
-               unset($item['author-avatar']);
-
-               unset($item['owner-link']);
-               unset($item['owner-name']);
-               unset($item['owner-avatar']);
-
                if ($item['network'] == Protocol::PHANTOM) {
                        logger('Missing network. Called by: '.System::callstack(), LOGGER_DEBUG);
 
@@ -1708,6 +1699,15 @@ class Item extends BaseObject
                unset($item['postopts']);
                unset($item['inform']);
 
+               // These fields aren't stored anymore in the item table, they are fetched upon request
+               unset($item['author-link']);
+               unset($item['author-name']);
+               unset($item['author-avatar']);
+
+               unset($item['owner-link']);
+               unset($item['owner-name']);
+               unset($item['owner-avatar']);
+
                DBA::transaction();
                $ret = DBA::insert('item', $item);