fix(reservations): fixes errors not being displayed when reservation system returns error. removed translations applied twice. (#11144)

This commit is contained in:
Stefan Plücken 2023-02-23 13:47:34 +01:00 committed by Дамян Минков
parent 581c2e621c
commit 9b7a5ffdd1
2 changed files with 5 additions and 5 deletions

View File

@ -98,7 +98,7 @@ function _upgradeRoleFinished(
name: authenticationError || connectionError,
...other
};
progress = authenticationError ? 0.5 : 0;
progress = 0;
}
return {

View File

@ -207,7 +207,7 @@ class LoginDialog extends Component<IProps, IState> {
let messageKey;
if (progress && progress < 1) {
messageKey = t('connection.FETCH_SESSION_ID');
messageKey = 'connection.FETCH_SESSION_ID';
} else if (error) {
const { name } = error;
@ -218,14 +218,14 @@ class LoginDialog extends Component<IProps, IState> {
&& credentials.jid === toJid(username, configHosts ?? { authdomain: '',
domain: '' })
&& credentials.password === password) {
messageKey = t('dialog.incorrectPassword');
messageKey = 'dialog.incorrectPassword';
}
} else if (name) {
messageKey = t('dialog.connectErrorWithMsg');
messageKey = 'dialog.connectErrorWithMsg';
messageOptions.msg = `${name} ${error.message}`;
}
} else if (connecting) {
messageKey = t('connection.CONNECTING');
messageKey = 'connection.CONNECTING';
}
if (messageKey) {