aboutsummaryrefslogtreecommitdiffstats
path: root/Zotlabs
diff options
context:
space:
mode:
authorMario Vavti <mario@mariovavti.com>2023-03-31 09:31:28 +0200
committerMario Vavti <mario@mariovavti.com>2023-03-31 09:31:28 +0200
commit5ec721b97823df32dca418bf2b5343b70c584114 (patch)
tree58ef5712164bd1c5c7e89e6eacd219671e88a7c5 /Zotlabs
parent24568c0e2f5f8537da7a6bc6a62b5785edf2cb9f (diff)
downloadvolse-hubzilla-5ec721b97823df32dca418bf2b5343b70c584114.tar.gz
volse-hubzilla-5ec721b97823df32dca418bf2b5343b70c584114.tar.bz2
volse-hubzilla-5ec721b97823df32dca418bf2b5343b70c584114.zip
likes not synced between clones
Diffstat (limited to 'Zotlabs')
-rw-r--r--Zotlabs/Module/Like.php19
1 files changed, 18 insertions, 1 deletions
diff --git a/Zotlabs/Module/Like.php b/Zotlabs/Module/Like.php
index ef41faedd..2cf792c8d 100644
--- a/Zotlabs/Module/Like.php
+++ b/Zotlabs/Module/Like.php
@@ -407,12 +407,20 @@ class Like extends Controller {
if (activity_match($rr['verb'], $activity))
$multi_undo = false;
+ $d = q("select * from item where id = %d",
+ intval($rr['id'])
+ );
+ if ($d) {
+ xchan_query($d);
+ $sync_item = fetch_post_tags($d);
+ Libsync::build_sync_packet($profile_uid, ['item' => [encode_item($sync_item[0], true)]]);
+ }
+
// drop_item was not done interactively, so we need to invoke the notifier
// in order to push the changes to connections
Master::Summon(array('Notifier', 'drop', $rr['id']));
-
}
if ($interactive)
@@ -562,6 +570,15 @@ class Like extends Controller {
call_hooks('post_local_end', $arr);
+ $r = q("select * from item where id = %d",
+ intval($post_id)
+ );
+ if ($r) {
+ xchan_query($r);
+ $sync_item = fetch_post_tags($r);
+ Libsync::build_sync_packet($profile_uid, ['item' => [encode_item($sync_item[0], true)]]);
+ }
+
if ($extended_like) {
$r = q("insert into likes (channel_id,liker,likee,iid,i_mid,verb,target_type,target_id,target) values (%d,'%s','%s',%d,'%s','%s','%s','%s','%s')",
intval($ch[0]['channel_id']),