add 12 hour cache for list count queries

This commit is contained in:
jeffvli
2025-11-29 17:54:57 -08:00
parent 8611bb9755
commit 3f704f1f35
5 changed files with 12 additions and 0 deletions
@@ -36,6 +36,7 @@ export const albumQueries = {
},
listCount: (args: QueryHookArgs<ListCountQuery<AlbumListQuery>>) => {
return queryOptions({
gcTime: 1000 * 60 * 60 * 12,
queryFn: ({ signal }) => {
return api.controller.getAlbumListCount({
apiClientProps: { serverId: args.serverId, signal },
@@ -47,6 +48,7 @@ export const albumQueries = {
args.query,
args.query?.artistIds?.length === 1 ? args.query?.artistIds[0] : undefined,
),
staleTime: 1000 * 60 * 60 * 12,
...args.options,
});
},