Skip to content

Commit

Permalink
remove success toast (#487)
Browse files Browse the repository at this point in the history
Co-authored-by: Mailn Nifeli Snieske <[email protected]>
  • Loading branch information
malinnsnieske and Mailn Nifeli Snieske authored Nov 12, 2024
1 parent 3931531 commit 33a1443
Show file tree
Hide file tree
Showing 3 changed files with 0 additions and 30 deletions.
10 changes: 0 additions & 10 deletions frontend/beCompliant/src/hooks/useDeleteComment.ts
Original file line number Diff line number Diff line change
Expand Up @@ -23,16 +23,6 @@ export function useDeleteComment(
});
},
onSuccess: async () => {
const toastId = 'delete-comment-success';
if (!toast.isActive(toastId)) {
toast({
title: 'Suksess',
description: 'Kommentaren din er slettet',
status: 'success',
duration: 5000,
isClosable: true,
});
}
await queryClient.invalidateQueries({
queryKey: apiConfig.comments.queryKey(contextId, recordId),
});
Expand Down
10 changes: 0 additions & 10 deletions frontend/beCompliant/src/hooks/useSubmitAnswers.ts
Original file line number Diff line number Diff line change
Expand Up @@ -31,16 +31,6 @@ export function useSubmitAnswers(
});
},
onSuccess: async () => {
const toastId = 'submit-answer-success';
if (!toast.isActive(toastId)) {
toast({
title: 'Suksess',
description: 'Svaret ditt er lagret',
status: 'success',
duration: 5000,
isClosable: true,
});
}
await queryClient.invalidateQueries({
queryKey: apiConfig.answers.queryKey(contextId, recordId),
});
Expand Down
10 changes: 0 additions & 10 deletions frontend/beCompliant/src/hooks/useSubmitComment.ts
Original file line number Diff line number Diff line change
Expand Up @@ -30,16 +30,6 @@ export function useSubmitComment(
});
},
onSuccess: async () => {
const toastId = 'submit-comment-success';
if (!toast.isActive(toastId)) {
toast({
title: 'Suksess',
description: 'Kommentaren din er lagret',
status: 'success',
duration: 5000,
isClosable: true,
});
}
await queryClient.invalidateQueries({
queryKey: apiConfig.comments.queryKey(contextId, recordId),
});
Expand Down

0 comments on commit 33a1443

Please sign in to comment.