X-Git-Url: https://git.mxchange.org/?a=blobdiff_plain;ds=sidebyside;f=mod%2Flike.php;h=7fc7b2b42c7ea2f0ca41b05e7d284923871f918b;hb=4af0119b7310e9731e60b11a14fd917580b95715;hp=b8de3ff6a1fe9f98dc5845c0bdc14d9ffdabd8a9;hpb=a0f65ca7a1b1fbc1a2d0f823940211377fc6e13e;p=friendica.git diff --git a/mod/like.php b/mod/like.php index b8de3ff6a1..7fc7b2b42c 100644 --- a/mod/like.php +++ b/mod/like.php @@ -1,25 +1,22 @@ argc > 1) ? Strings::removeTags(trim($a->argv[1])) : 0); + $item_id = (($a->argc > 1) ? Strings::escapeTags(trim($a->argv[1])) : 0); $r = Item::performLike($item_id, $verb); if (!$r) { @@ -27,10 +24,10 @@ function like_content(App $a) { } // See if we've been passed a return path to redirect to - $return_path = ((x($_REQUEST,'return')) ? $_REQUEST['return'] : ''); + $return_path = defaults($_REQUEST, 'return', ''); like_content_return($a, $return_path); - killme(); // NOTREACHED + exit(); } @@ -48,6 +45,4 @@ function like_content_return(App $a, $return_path) { $a->internalRedirect($return_path . $rand); } - - killme(); }