minor tweak with handle error

This commit is contained in:
Reinaldo Neto 2023-01-11 12:43:05 -03:00
parent 2dc8a0c355
commit 3db96db70c
1 changed files with 3 additions and 0 deletions

View File

@ -135,6 +135,9 @@ const ChangeAvatarView = () => {
if (e.data && e.data.error.includes('[error-too-many-requests]')) {
return showErrorAlert(e.data.error);
}
if (e.error && e.error === 'error-avatar-invalid-url') {
return showErrorAlert(I18n.t(e.error, { url: e.details.url }));
}
if (I18n.isTranslated(e.error)) {
return showErrorAlert(I18n.t(e.error));
}