mirror of
https://github.com/hasura/graphql-engine.git
synced 2024-12-15 09:22:43 +03:00
ask for confirmation before deleting event triggers (close #599)
This commit is contained in:
parent
4643458cf9
commit
ffa0938a86
@ -20,8 +20,12 @@ class Settings extends Component {
|
||||
)[0];
|
||||
triggerSchema = triggerSchema ? triggerSchema : {};
|
||||
|
||||
const handleDeleteTrigger = () => {
|
||||
dispatch(deleteTrigger(triggerName));
|
||||
const handleDeleteTrigger = e => {
|
||||
e.preventDefault();
|
||||
const isOk = confirm('Are you sure?');
|
||||
if (isOk) {
|
||||
dispatch(deleteTrigger(triggerName));
|
||||
}
|
||||
};
|
||||
|
||||
return (
|
||||
|
Loading…
Reference in New Issue
Block a user