]> git.mxchange.org Git - friendica.git/commitdiff
Ensure to always have stored the receivers
authorMichael <heluecht@pirati.ca>
Mon, 6 Nov 2023 09:57:23 +0000 (09:57 +0000)
committerMichael <heluecht@pirati.ca>
Mon, 6 Nov 2023 09:57:23 +0000 (09:57 +0000)
src/Content/Item.php
src/Model/Item.php

index d28ec4066d66e250eea7f047219710f30598892d..ab5ff1698f8db1f9d8bf8ae1dd406f14e93d902d 100644 (file)
@@ -1049,8 +1049,6 @@ class Item
                        Tag::createImplicitMentions($post['uri-id'], $post['thr-parent-id']);
                }
 
-               ActivityPub\Transmitter::storeReceiversForItem($post);
-
                Hook::callAll('post_local_end', $post);
 
                $author = DBA::selectFirst('contact', ['thumb'], ['uid' => $post['uid'], 'self' => true]);
index 18b56215ce39ca9a680e64fc062f693c84dca392..491050c582f2f7d3acff45f30cd052e24196b25b 100644 (file)
@@ -1414,10 +1414,12 @@ class Item
                }
 
                if (!empty($source) && ($transmit || DI::config()->get('debug', 'store_source'))) {
-                       Post\Activity::insert($item['uri-id'], $source);
+                       Post\Activity::insert($posted_item['uri-id'], $source);
                }
 
                if ($transmit) {
+                       ActivityPub\Transmitter::storeReceiversForItem($posted_item);
+
                        Worker::add(['priority' => $priority, 'dont_fork' => true], 'Notifier', $notify_type, (int)$posted_item['uri-id'], (int)$posted_item['uid']);
                }