X-Git-Url: https://git.mxchange.org/?a=blobdiff_plain;f=include%2Flike.php;h=210bde690656e84e777c0b6771dc6ee57f867939;hb=564bc2290064c81adc43dda5c3e30d1f7038223d;hp=94ff33a6996f4dd204993923117d9e17fe072fa1;hpb=4c04a78d1b6f14ce90e4ca0b23e356d234c4a296;p=friendica.git diff --git a/include/like.php b/include/like.php index 94ff33a699..210bde6906 100644 --- a/include/like.php +++ b/include/like.php @@ -48,10 +48,8 @@ function do_like($item_id, $verb) { break; } - logger('like: verb ' . $verb . ' item ' . $item_id); - $r = q("SELECT * FROM `item` WHERE `id` = '%s' OR `uri` = '%s' LIMIT 1", dbesc($item_id), dbesc($item_id) @@ -109,14 +107,14 @@ function do_like($item_id, $verb) { if ((local_user()) && (local_user() == $owner_uid)) { $contact = $owner; - } - else { + } else { $r = q("SELECT * FROM `contact` WHERE `id` = %d AND `uid` = %d LIMIT 1", intval($_SESSION['visitor_id']), intval($owner_uid) ); - if (dbm::is_result($r)) + if (dbm::is_result($r)) { $contact = $r[0]; + } } if (! $contact) { return false; @@ -249,7 +247,7 @@ EOT; // Save the author information for the like in case we need to relay to Diaspora - diaspora::store_like_signature($contact, $post_id); + Diaspora::store_like_signature($contact, $post_id); $arr['id'] = $post_id;