mirror of
https://framagit.org/hubzilla/core.git
synced 2026-06-21 00:52:33 -04:00
make sure we do not mix up likes on direct messages and commments on direct messages in notices
This commit is contained in:
@@ -2423,9 +2423,14 @@ function send_status_notifications($post_id,$item) {
|
||||
$unfollowed = false;
|
||||
|
||||
$parent = 0;
|
||||
$is_reaction = false;
|
||||
|
||||
$type = ((intval($item['item_private']) === 2) ? NOTIFY_MAIL : NOTIFY_COMMENT);
|
||||
|
||||
if(array_key_exists('verb',$item) && (activity_match($item['verb'], ACTIVITY_LIKE) || activity_match($item['verb'], ACTIVITY_DISLIKE))) {
|
||||
|
||||
$type = NOTIFY_LIKE;
|
||||
|
||||
$r = q("select id from item where mid = '%s' and uid = %d limit 1",
|
||||
dbesc($item['thr_parent']),
|
||||
intval($item['uid'])
|
||||
@@ -2494,7 +2499,7 @@ function send_status_notifications($post_id,$item) {
|
||||
|
||||
|
||||
Enotify::submit(array(
|
||||
'type' => ((intval($item['item_private']) === 2) ? NOTIFY_MAIL : NOTIFY_COMMENT),
|
||||
'type' => $type,
|
||||
'from_xchan' => $item['author_xchan'],
|
||||
'to_xchan' => $r[0]['channel_hash'],
|
||||
'item' => $item,
|
||||
|
||||
Reference in New Issue
Block a user