X-Git-Url: https://git.mxchange.org/?a=blobdiff_plain;f=include%2Fauth.php;h=2ca9c3efb29e7937b326b40ee8e5d2665693cd57;hb=6a8a36f12d00f35004fbb034972ca87dd1a3c4f5;hp=d1917b8b30903138f18a8cd17203588c8c8f1361;hpb=293436e5fd5110220c969513858dbb979f1f35d3;p=friendica.git diff --git a/include/auth.php b/include/auth.php index d1917b8b30..2ca9c3efb2 100644 --- a/include/auth.php +++ b/include/auth.php @@ -50,7 +50,7 @@ if (isset($_SESSION) && x($_SESSION,'authenticated') && (!x($_POST,'auth-params' $r = q("SELECT * FROM `contact` WHERE `id` = %d LIMIT 1", intval($_SESSION['visitor_id']) ); - if (count($r)) { + if (dbm::is_result($r)) { $a->contact = $r[0]; } } @@ -73,7 +73,7 @@ if (isset($_SESSION) && x($_SESSION,'authenticated') && (!x($_POST,'auth-params' intval($_SESSION['uid']) ); - if (!count($r)) { + if (!dbm::is_result($r)) { nuke_session(); goaway(z_root()); } @@ -169,7 +169,7 @@ if (isset($_SESSION) && x($_SESSION,'authenticated') && (!x($_POST,'auth-params' dbesc(trim($_POST['username'])), dbesc($encrypted) ); - if (count($r)) + if (dbm::is_result($r)) $record = $r[0]; }