From c5dec5a0b9bea78ab3e80dca3704daa3769ffc26 Mon Sep 17 00:00:00 2001 From: tripathyr Date: Fri, 19 Nov 2021 18:31:53 +0530 Subject: [PATCH] Update authenticateMe.php --- ajax/authenticateMe.php | 28 ++++++++++++++++------------ 1 file changed, 16 insertions(+), 12 deletions(-) diff --git a/ajax/authenticateMe.php b/ajax/authenticateMe.php index baad8aa..d66071a 100644 --- a/ajax/authenticateMe.php +++ b/ajax/authenticateMe.php @@ -82,17 +82,24 @@ $std->error = true; if ($permitted_status == true){ $UserClass->update_flo_details($floID, $s_id, $pubKey); $_SESSION['user_id'] = $UserClass->getUserID($floID); - } - } else { - $std->message[] = "FLO ID is either not registered or not active."; - $std->error = true; + $std->message[] = "Authentication Succeeded."; + $std->error = false; echo json_encode($std); - return false; + return true; + } else { + if (($UserClass->check_flo_id_registration_status($floID) == true) && ($UserClass->check_flo_id_active_status($floID) != true)) { + $std->message[] = "FLO ID is not active. Please contact RanchiMall Team. "; + $std->error = true; + echo json_encode($std); + return false; } + if ($UserClass->check_flo_id_registration_status($floID) != true ) { + $std->message[] = "Your FLO ID is not registered. Please contact RanchiMall Team and get yourself registered."; + $std->error = true; + echo json_encode($std); + return false; } + } } - $std->message[] = "Authentication Succeeded."; - $std->error = false; - echo json_encode($std); - return true; + } @@ -108,6 +115,3 @@ $std->error = true; echo json_encode($std); return false; } - - -