diff --git a/htdocs/main.inc.php b/htdocs/main.inc.php index 4e1745413ce..01a999c6a8b 100644 --- a/htdocs/main.inc.php +++ b/htdocs/main.inc.php @@ -553,7 +553,7 @@ if (!defined('NOLOGIN')) // Validation of login/pass/entity // If ok, the variable login will be returned // If error, we will put error message in session under the name dol_loginmesg - if ($test && $goontestloop && GETPOST('actionlogin', 'aZ09') == 'login') + if ($test && $goontestloop && (GETPOST('actionlogin', 'aZ09') == 'login' || $dolibarr_main_authentication != 'dolibarr')) { $login = checkLoginPassEntity($usertotest, $passwordtotest, $entitytotest, $authmode); if ($login)