diff --git a/frontend/app/src/components/modals/modal-delete-object.tsx b/frontend/app/src/components/modals/modal-delete-object.tsx index 72f339542f..a6c6fec35d 100644 --- a/frontend/app/src/components/modals/modal-delete-object.tsx +++ b/frontend/app/src/components/modals/modal-delete-object.tsx @@ -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(