Skip success toast and saving flag on editable panel save.
This commit is contained in:
@@ -106,15 +106,13 @@ class EditablePanelTileBase extends Component {
|
||||
|
||||
const { onSave } = this.props;
|
||||
const { draft } = this.state;
|
||||
this.setState({ saving: true, error: null });
|
||||
|
||||
try {
|
||||
await onSave(draft);
|
||||
this.setState({ editing: false, draft: null, saving: false, error: null });
|
||||
enqueueSnackbar('Gespeichert.', { variant: 'success' });
|
||||
} catch (err) {
|
||||
const normalized = notifyError(err);
|
||||
this.setState({ saving: false, error: normalized.message });
|
||||
this.setState({ error: normalized.message });
|
||||
}
|
||||
};
|
||||
|
||||
|
||||
Reference in New Issue
Block a user