localize_item() thinks all likes on posts are likes on comments because we didn't pass any info in the activity object to distinguish them from each other.
This commit is contained in:
parent
2e14dc242e
commit
b9314935e6
@ -137,7 +137,7 @@ function localize_item(&$item){
|
|||||||
case ACTIVITY_OBJ_NOTE:
|
case ACTIVITY_OBJ_NOTE:
|
||||||
default:
|
default:
|
||||||
$post_type = t('status');
|
$post_type = t('status');
|
||||||
if($obj['id'] != $item['mid'])
|
if($obj['mid'] != $obj['parent_mid'])
|
||||||
$post_type = t('comment');
|
$post_type = t('comment');
|
||||||
break;
|
break;
|
||||||
}
|
}
|
||||||
|
@ -110,6 +110,7 @@ function like_content(&$a) {
|
|||||||
$obj = json_encode(array(
|
$obj = json_encode(array(
|
||||||
'type' => $objtype,
|
'type' => $objtype,
|
||||||
'id' => $item['mid'],
|
'id' => $item['mid'],
|
||||||
|
'parent' => (($item['thr_parent']) ? $item['thr_parent'] : $item['parent_mid']),
|
||||||
'link' => $links,
|
'link' => $links,
|
||||||
'title' => $item['title'],
|
'title' => $item['title'],
|
||||||
'content' => $item['body'],
|
'content' => $item['body'],
|
||||||
|
Reference in New Issue
Block a user