banned customers cannot login

This commit is contained in:
Ibnu Maksum 2024-05-17 09:19:04 +07:00
parent d84cf96d01
commit 9521e96495
No known key found for this signature in database
GPG key ID: 7FC82848810579E5

View file

@ -24,6 +24,9 @@ switch ($do) {
$d = ORM::for_table('tbl_customers')->where('username', $username)->find_one();
if ($d) {
$d_pass = $d['password'];
if($d['status'] != 'Banned'){
_alert(Lang::T('This account status').' : '.Lang::T($c['status']),'danger', "");
}
if (Password::_uverify($password, $d_pass) == true) {
$_SESSION['uid'] = $d['id'];
User::setCookie($d['id']);