Skip to content

Commit

Permalink
improve on delete
Browse files Browse the repository at this point in the history
  • Loading branch information
pa-lem committed Sep 18, 2024
1 parent 5c05252 commit 20b99ec
Showing 1 changed file with 3 additions and 3 deletions.
6 changes: 3 additions & 3 deletions frontend/app/src/components/modals/modal-delete-object.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -54,12 +54,12 @@ export default function ModalDeleteObject({ label, rowToDelete, open, close, onD
context: { branch: branch?.name, date },
});

await graphqlClient.refetchQueries({ include: [objectKind!] });

close();
if (objectKind) await graphqlClient.refetchQueries({ include: [objectKind!] });

if (onDelete) onDelete();

close();

toast(
<Alert
type={ALERT_TYPES.SUCCESS}
Expand Down

0 comments on commit 20b99ec

Please sign in to comment.