Reset schema mutations on erroring
This commit is contained in:
parent
326a90a41e
commit
dad689c787
|
@ -24,6 +24,8 @@
|
|||
await datasource.actions.saveSchemaMutations()
|
||||
} catch (e) {
|
||||
notifications.error(e.message)
|
||||
} finally {
|
||||
datasource.actions.resetSchemaMutations()
|
||||
}
|
||||
dispatch(visible ? "show-column" : "hide-column")
|
||||
}
|
||||
|
|
|
@ -204,6 +204,10 @@ export const createActions = context => {
|
|||
...$definition,
|
||||
schema: newSchema,
|
||||
})
|
||||
resetSchemaMutations()
|
||||
}
|
||||
|
||||
const resetSchemaMutations = () => {
|
||||
schemaMutations.set({})
|
||||
}
|
||||
|
||||
|
@ -253,6 +257,7 @@ export const createActions = context => {
|
|||
addSchemaMutation,
|
||||
addSchemaMutations,
|
||||
saveSchemaMutations,
|
||||
resetSchemaMutations,
|
||||
},
|
||||
},
|
||||
}
|
||||
|
|
Loading…
Reference in New Issue