X-Git-Url: https://git.mxchange.org/?a=blobdiff_plain;f=mod%2Fshare.php;h=928ccdef263efc45b7f24f66c6c8c123f945888a;hb=a7ce601580b07e9b3e7653cbdb0a9b6bbb5c474e;hp=f3a221eb8ef4c985f9b8ad9e86a523efb8a4fa61;hpb=0c764684bb32a9432fd161e62db907efb78af1a5;p=friendica.git diff --git a/mod/share.php b/mod/share.php index f3a221eb8e..928ccdef26 100644 --- a/mod/share.php +++ b/mod/share.php @@ -1,7 +1,5 @@ argc > 1) ? intval($a->argv[1]) : 0); if((! $post_id) || (! local_user())) @@ -14,7 +12,7 @@ function share_init(&$a) { intval($post_id), intval(local_user()) ); - if(! count($r) || ($r[0]['private'] == 1)) + if(! dbm::is_result($r) || ($r[0]['private'] == 1)) killme(); if (!intval(get_config('system','old_share'))) { @@ -42,9 +40,7 @@ function share_init(&$a) { echo $o; killme(); } -} -if(! function_exists('share_header')) { function share_header($author, $profile, $avatar, $guid, $posted, $link) { $header = "[share author='".str_replace(array("'", "[", "]"), array("'", "[", "]"),$author). "' profile='".str_replace(array("'", "[", "]"), array("'", "[", "]"),$profile). @@ -60,4 +56,3 @@ function share_header($author, $profile, $avatar, $guid, $posted, $link) { return $header; } -}