diff --git a/sources/identify.php b/sources/identify.php index e2e2b4dec..cb2523075 100755 --- a/sources/identify.php +++ b/sources/identify.php @@ -2115,7 +2115,7 @@ public function getUserInfo($login, $enable_ad_user_auto_creation, $oauth2_enabl $oauth2LoginOngoing = isset($session->get('userOauth2Info')['oauth2LoginOngoing']) ? $session->get('userOauth2Info')['oauth2LoginOngoing'] : false; $data['oauth2_login_ongoing'] = $oauth2LoginOngoing; $data['ldap_user_to_be_created'] = $enable_ad_user_auto_creation === true && DB::count() === 0 && $oauth2LoginOngoing !== true ? true : false; - $data['oauth2_user_to_be_created'] = $oauth2_enabled === true && DB::count() === 0 && $oauth2LoginOngoing === true ? true : false; + $data['oauth2_user_to_be_created'] = (bool)$oauth2_enabled === true && DB::count() === 0 && $oauth2LoginOngoing === true ? true : false; return $data; } @@ -2687,4 +2687,4 @@ function identifyDoAzureChecks( 'mfaData' => ['message' => $lang->get('wrong_mfa_code')], 'mfaQRCodeInfos' => false, ]; -} \ No newline at end of file +}