mirror of
https://github.com/the-djmaze/snappymail.git
synced 2026-09-06 16:07:03 +03:00
Detailed error message on account switch failure for #1594
This commit is contained in:
parent
288ff23f2b
commit
7a1652972d
1 changed files with 7 additions and 3 deletions
|
|
@ -205,9 +205,13 @@ trait UserAuth
|
||||||
if (!isset($aAccounts[$sEmail])) {
|
if (!isset($aAccounts[$sEmail])) {
|
||||||
throw new ClientException(Notifications::AccountDoesNotExist);
|
throw new ClientException(Notifications::AccountDoesNotExist);
|
||||||
}
|
}
|
||||||
$oAccount = AdditionalAccount::NewInstanceFromTokenArray(
|
try {
|
||||||
$this, $aAccounts[$sEmail]
|
$oAccount = AdditionalAccount::NewInstanceFromTokenArray(
|
||||||
);
|
$this, $aAccounts[$sEmail], true
|
||||||
|
);
|
||||||
|
} catch (\Throwable $e) {
|
||||||
|
throw new ClientException(Notifications::AccountSwitchFailed, $e);
|
||||||
|
}
|
||||||
if (!$oAccount) {
|
if (!$oAccount) {
|
||||||
throw new ClientException(Notifications::AccountSwitchFailed);
|
throw new ClientException(Notifications::AccountSwitchFailed);
|
||||||
}
|
}
|
||||||
|
|
|
||||||
Loading…
Add table
Add a link
Reference in a new issue