mirror of
https://github.com/wassname/talk.git
synced 2026-07-13 17:45:56 +08:00
Display errors that come from the backend.
This commit is contained in:
@@ -22,8 +22,8 @@ export const createDisplayName = (userId, formData) => dispatch => {
|
||||
dispatch(hideCreateDisplayNameDialog());
|
||||
dispatch(updateDisplayName(formData.displayName));
|
||||
})
|
||||
.catch(() => {
|
||||
dispatch(createDisplayNameFailure(lang.t('createdisplay.errorCreate')));
|
||||
.catch(error => {
|
||||
dispatch(createDisplayNameFailure(lang.t(`error.${error.message}`)));
|
||||
});
|
||||
};
|
||||
|
||||
|
||||
Reference in New Issue
Block a user