]> git.mxchange.org Git - friendica.git/blobdiff - include/like.php
Merge remote-tracking branch 'upstream/develop' into 1610-performance
[friendica.git] / include / like.php
index 49534ea6137d041ce5ef291c051b9ca670d97b3e..118ec81ca1c35e47ca966c997c254a2a379234d1 100644 (file)
@@ -153,7 +153,7 @@ function do_like($item_id, $verb) {
                );
 
                $like_item_id = $like_item['id'];
-               proc_run('php',"include/notifier.php","like","$like_item_id");
+               proc_run(PRIORITY_HIGH, "include/notifier.php", "like", $like_item_id);
 
                return true;
        }
@@ -161,7 +161,7 @@ function do_like($item_id, $verb) {
        $uri = item_new_uri($a->get_hostname(),$owner_uid);
 
        $post_type = (($item['resource-id']) ? t('photo') : t('status'));
-       if($item['obj_type'] === ACTIVITY_OBJ_EVENT)
+       if($item['object-type'] === ACTIVITY_OBJ_EVENT)
                $post_type = t('event');
        $objtype = (($item['resource-id']) ? ACTIVITY_OBJ_PHOTO : ACTIVITY_OBJ_NOTE );
        $link = xmlify('<link rel="alternate" type="text/html" href="' . $a->get_baseurl() . '/display/' . $owner['nickname'] . '/' . $item['id'] . '" />' . "\n") ;
@@ -194,6 +194,7 @@ EOT;
 
        $arr = array();
 
+       $arr['guid'] = get_guid(32);
        $arr['uri'] = $uri;
        $arr['uid'] = $owner_uid;
        $arr['contact-id'] = $contact['id'];
@@ -244,7 +245,7 @@ EOT;
 
        call_hooks('post_local_end', $arr);
 
-       proc_run('php',"include/notifier.php","like","$post_id");
+       proc_run(PRIORITY_HIGH, "include/notifier.php", "like", $post_id);
 
        return true;
 }