Error message if the delete fails
This commit is contained in:
parent
4ec49c4966
commit
76b321accd
11 changed files with 111 additions and 43 deletions
|
|
@ -41,10 +41,12 @@ const Triggers = () => {
|
|||
const complianceConfig =
|
||||
data?.config && fromNamespace('compliance')(data.config)
|
||||
const rejectAddressReuse = complianceConfig?.rejectAddressReuse ?? false
|
||||
const [error, setError] = useState(null)
|
||||
|
||||
const [saveConfig, { error }] = useMutation(SAVE_CONFIG, {
|
||||
const [saveConfig] = useMutation(SAVE_CONFIG, {
|
||||
onCompleted: () => setWizard(false),
|
||||
refetchQueries: () => ['getData']
|
||||
refetchQueries: () => ['getData'],
|
||||
onError: error => setError(error)
|
||||
})
|
||||
|
||||
const add = rawConfig => {
|
||||
|
|
@ -60,6 +62,7 @@ const Triggers = () => {
|
|||
}
|
||||
|
||||
const save = config => {
|
||||
setError(null)
|
||||
return saveConfig({
|
||||
variables: { config: { triggers: toServer(config.triggers) } }
|
||||
})
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue