Client: ResetApplicationDialog: add success toast
This commit is contained in:
parent
c6e1c58e97
commit
4d60816027
@ -14,10 +14,11 @@ class ResetApplicationDialogComponent extends React.Component {
|
||||
}
|
||||
|
||||
resetApp = async () => {
|
||||
const { resetTfaApp, id, onClose, history } = this.props;
|
||||
const { t, resetTfaApp, id, onClose, history } = this.props;
|
||||
onClose && onClose();
|
||||
try {
|
||||
const res = await resetTfaApp(id);
|
||||
toastr.success(t("SuccessResetApplication"));
|
||||
if (res) history.push(res.replace(window.location.origin, ""));
|
||||
} catch (e) {
|
||||
toastr.error(e);
|
||||
|
Loading…
Reference in New Issue
Block a user