parent
a59d1b22f6
commit
9a0f0181a5
14
mod/like.php
14
mod/like.php
@ -299,7 +299,8 @@ function like_content(&$a) {
|
|||||||
|
|
||||||
|
|
||||||
$verbs = " '".dbesc($activity)."' ";
|
$verbs = " '".dbesc($activity)."' ";
|
||||||
$multi_undo = 0;
|
|
||||||
|
$multi_undo = false;
|
||||||
|
|
||||||
// event participation and consensus items are essentially radio toggles. If you make a subsequent choice,
|
// event participation and consensus items are essentially radio toggles. If you make a subsequent choice,
|
||||||
// we need to eradicate your first 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) {
|
if($activity === ACTIVITY_AGREE || $activity === ACTIVITY_DISAGREE || $activity === ACTIVITY_ABSTAIN) {
|
||||||
$verbs = " '" . dbesc(ACTIVITY_AGREE) . "','" . dbesc(ACTIVITY_DISAGREE) . "','" . dbesc(ACTIVITY_ABSTAIN) . "' ";
|
$verbs = " '" . dbesc(ACTIVITY_AGREE) . "','" . dbesc(ACTIVITY_DISAGREE) . "','" . dbesc(ACTIVITY_ABSTAIN) . "' ";
|
||||||
$multi_undo = 1;
|
$multi_undo = true;
|
||||||
}
|
}
|
||||||
|
|
||||||
$item_normal = item_normal();
|
$item_normal = item_normal();
|
||||||
|
|
||||||
$r = q("SELECT id, parent, uid, verb FROM item WHERE verb in ( $verbs ) $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']),
|
dbesc($observer['xchan_hash']),
|
||||||
intval($item_id),
|
|
||||||
dbesc($item['mid']),
|
dbesc($item['mid']),
|
||||||
intval($owner_uid)
|
intval($owner_uid)
|
||||||
);
|
);
|
||||||
@ -338,6 +338,12 @@ function like_content(&$a) {
|
|||||||
// don't fall through and create another
|
// don't fall through and create another
|
||||||
if(activity_match($rr['verb'],$activity))
|
if(activity_match($rr['verb'],$activity))
|
||||||
$multi_undo = false;
|
$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)
|
if($interactive)
|
||||||
|
File diff suppressed because it is too large
Load Diff
@ -1 +1 @@
|
|||||||
2016-03-03.1325H
|
2016-03-04.1326H
|
||||||
|
Reference in New Issue
Block a user