From c50b1346fead88724f6bf183977d00649e1528a3 Mon Sep 17 00:00:00 2001 From: ALi Josheghani Date: Sat, 14 Sep 2024 22:02:43 +0330 Subject: [PATCH] Refactor: Add dependencies to useEffect in Profile component --- src/pages/profile/index.tsx | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/src/pages/profile/index.tsx b/src/pages/profile/index.tsx index 5c64bd8..7a44968 100644 --- a/src/pages/profile/index.tsx +++ b/src/pages/profile/index.tsx @@ -66,7 +66,7 @@ const Profile = () => { } else { console.error("Track ID is missing or invalid."); } - }, []); + }, [mutation,query]); const { data, isLoading, isFetching, error } = useQuery({ queryKey: ["profile", mutation],