From 46abda9041fe18779f6b3b1335ec77abae052317 Mon Sep 17 00:00:00 2001 From: Sheen Capadngan Date: Mon, 1 Jul 2024 20:22:59 +0800 Subject: [PATCH] misc: add org scoping to mutation --- frontend/src/hooks/api/users/mutation.tsx | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/frontend/src/hooks/api/users/mutation.tsx b/frontend/src/hooks/api/users/mutation.tsx index 8785533c5..26e932ac6 100644 --- a/frontend/src/hooks/api/users/mutation.tsx +++ b/frontend/src/hooks/api/users/mutation.tsx @@ -107,8 +107,8 @@ export const useUpdateUserProjectFavorites = () => { return {}; }, - onSuccess: () => { - queryClient.invalidateQueries(userKeys.userProjectFavorites); + onSuccess: (_, { orgId }) => { + queryClient.invalidateQueries(userKeys.userProjectFavorites(orgId)); } }); };