This commit is contained in:
cv
2021-04-10 15:30:32 +02:00
parent 7293b0dfd9
commit a65f816477
4 changed files with 30 additions and 19 deletions
@@ -35,7 +35,7 @@ export default function EventListWrapper() {
switch (action) {
case 'add':
try {
const event = await addEvent
await addEvent
.mutateAsync(payload)
.then(queryClient.invalidateQueries('events'));
} catch (error) {
@@ -44,7 +44,7 @@ export default function EventListWrapper() {
break;
case 'update':
try {
const event = await updateEvent
await updateEvent
.mutateAsync(payload)
.then(queryClient.invalidateQueries('events'));
} catch (error) {
@@ -53,7 +53,7 @@ export default function EventListWrapper() {
break;
case 'delete':
try {
const event = await deleteEvent
await deleteEvent
.mutateAsync(payload)
.then(queryClient.invalidateQueries('events'));
} catch (error) {