diff options
author | Haakon Meland Eriksen <haakon.eriksen@far.no> | 2016-03-05 10:01:42 +0100 |
---|---|---|
committer | Haakon Meland Eriksen <haakon.eriksen@far.no> | 2016-03-05 10:01:42 +0100 |
commit | d7466ade46415814edc39b6ca8662c7e58966010 (patch) | |
tree | 869b409e78a08e1ab4fedd8b9ded0b1b798b3ff0 /mod | |
parent | 01c0e5c46cb2dbb5e4939f326be5bb638edea3d2 (diff) | |
parent | 86f840843fccf8f3c1625a3494e13bce586e68d1 (diff) | |
download | volse-hubzilla-d7466ade46415814edc39b6ca8662c7e58966010.tar.gz volse-hubzilla-d7466ade46415814edc39b6ca8662c7e58966010.tar.bz2 volse-hubzilla-d7466ade46415814edc39b6ca8662c7e58966010.zip |
Merge remote-tracking branch 'upstream/master'
Diffstat (limited to 'mod')
-rwxr-xr-x | mod/like.php | 14 |
1 files changed, 10 insertions, 4 deletions
diff --git a/mod/like.php b/mod/like.php index 26c39bf3b..1de7882e9 100755 --- a/mod/like.php +++ b/mod/like.php @@ -299,7 +299,8 @@ function like_content(&$a) { $verbs = " '".dbesc($activity)."' "; - $multi_undo = 0; + + $multi_undo = false; // event participation and consensus items are essentially radio toggles. If you make a subsequent choice, // we need to eradicate your first choice. @@ -310,15 +311,14 @@ function like_content(&$a) { } if($activity === ACTIVITY_AGREE || $activity === ACTIVITY_DISAGREE || $activity === ACTIVITY_ABSTAIN) { $verbs = " '" . dbesc(ACTIVITY_AGREE) . "','" . dbesc(ACTIVITY_DISAGREE) . "','" . dbesc(ACTIVITY_ABSTAIN) . "' "; - $multi_undo = 1; + $multi_undo = true; } $item_normal = item_normal(); $r = q("SELECT id, parent, uid, verb FROM item WHERE verb in ( $verbs ) $item_normal - AND author_xchan = '%s' AND ( parent = %d OR thr_parent = '%s') and uid = %d ", + AND author_xchan = '%s' AND thr_parent = '%s' and uid = %d ", dbesc($observer['xchan_hash']), - intval($item_id), dbesc($item['mid']), intval($owner_uid) ); @@ -338,6 +338,12 @@ function like_content(&$a) { // don't fall through and create another if(activity_match($rr['verb'],$activity)) $multi_undo = false; + + // drop_item was not done interactively, so we need to invoke the notifier + // in order to push the changes to connections + + proc_run('php','include/notifier.php','drop',$rr['id']); + } if($interactive) |