diff --git a/snappymail/v/0.0.0/app/libraries/RainLoop/Actions/UserAuth.php b/snappymail/v/0.0.0/app/libraries/RainLoop/Actions/UserAuth.php index 92f59a489..7cf2a82d7 100644 --- a/snappymail/v/0.0.0/app/libraries/RainLoop/Actions/UserAuth.php +++ b/snappymail/v/0.0.0/app/libraries/RainLoop/Actions/UserAuth.php @@ -205,9 +205,13 @@ trait UserAuth if (!isset($aAccounts[$sEmail])) { throw new ClientException(Notifications::AccountDoesNotExist); } - $oAccount = AdditionalAccount::NewInstanceFromTokenArray( - $this, $aAccounts[$sEmail] - ); + try { + $oAccount = AdditionalAccount::NewInstanceFromTokenArray( + $this, $aAccounts[$sEmail], true + ); + } catch (\Throwable $e) { + throw new ClientException(Notifications::AccountSwitchFailed, $e); + } if (!$oAccount) { throw new ClientException(Notifications::AccountSwitchFailed); }