aboutsummaryrefslogtreecommitdiffstats
path: root/Zotlabs/Lib/Activity.php
diff options
context:
space:
mode:
authorMario <mario@mariovavti.com>2021-12-22 09:50:50 +0000
committerMario <mario@mariovavti.com>2021-12-22 09:50:50 +0000
commit27ebeffad41e39dda80159bc27605f5f247174c9 (patch)
tree7da422007d15240c83bc57a60c2e953ac888eab0 /Zotlabs/Lib/Activity.php
parent07110cee170970b840bbb479e9271a12b4810137 (diff)
downloadvolse-hubzilla-27ebeffad41e39dda80159bc27605f5f247174c9.tar.gz
volse-hubzilla-27ebeffad41e39dda80159bc27605f5f247174c9.tar.bz2
volse-hubzilla-27ebeffad41e39dda80159bc27605f5f247174c9.zip
update_poll() can be called many times in a row for the same item if a multiple poll is being updated. This could result in the queueworker not processing duplicates. We are now adding the source item mid to the notifier call as the third argument (fragment) so that the queueworker will not think they are duplicates. The fragment is also passed to the deliver_hooks call in the notifier
Diffstat (limited to 'Zotlabs/Lib/Activity.php')
-rw-r--r--Zotlabs/Lib/Activity.php4
1 files changed, 3 insertions, 1 deletions
diff --git a/Zotlabs/Lib/Activity.php b/Zotlabs/Lib/Activity.php
index 8e5a4e1a6..ef18040c0 100644
--- a/Zotlabs/Lib/Activity.php
+++ b/Zotlabs/Lib/Activity.php
@@ -2115,6 +2115,7 @@ class Activity {
}
static function update_poll($item, $post) {
+
$multi = false;
$mid = $post['mid'];
$content = $post['title'];
@@ -2199,7 +2200,8 @@ class Activity {
dbesc(datetime_convert()),
intval($item['id'])
);
- Master::Summon(['Notifier', 'wall-new', $item['id']]);
+
+ Master::Summon(['Notifier', 'wall-new', $item['id'], $post['mid'] /* trick queueworker de-duplication */ ]);
return true;
}