From bf0c8a8007f2d612511a98a917f2cf70bdd93f77 Mon Sep 17 00:00:00 2001 From: Alex Kim Date: Tue, 26 Nov 2024 02:54:50 +1100 Subject: [PATCH] Fixed refresh not refetching next-up and continue watching --- app/(auth)/(tabs)/(home)/index.tsx | 12 ++---------- 1 file changed, 2 insertions(+), 10 deletions(-) diff --git a/app/(auth)/(tabs)/(home)/index.tsx b/app/(auth)/(tabs)/(home)/index.tsx index d392d242..26e4c0e8 100644 --- a/app/(auth)/(tabs)/(home)/index.tsx +++ b/app/(auth)/(tabs)/(home)/index.tsx @@ -167,19 +167,11 @@ export default function index() { setLoading(true); await queryClient.invalidateQueries({ queryKey: ["home"], - refetchType: "all", - type: "all", - exact: false, - }); - await queryClient.invalidateQueries({ - queryKey: ["home"], - refetchType: "all", type: "all", exact: false, }); await queryClient.invalidateQueries({ queryKey: ["item"], - refetchType: "all", type: "all", exact: false, }); @@ -240,7 +232,7 @@ export default function index() { const ss: Section[] = [ { title: "Continue Watching", - queryKey: ["home", "resumeItems", user.Id], + queryKey: ["home", "resumeItems"], queryFn: async () => ( await getItemsApi(api).getResumeItems({ @@ -254,7 +246,7 @@ export default function index() { }, { title: "Next Up", - queryKey: ["home", "nextUp-all", user?.Id], + queryKey: ["home", "nextUp-all"], queryFn: async () => ( await getTvShowsApi(api).getNextUp({