mirror of
https://github.com/MODSetter/SurfSense.git
synced 2026-07-20 23:21:06 +02:00
feat(model-connections): refetch setup status on window focus
This commit is contained in:
parent
4b4efc243a
commit
ad91a3bfa5
1 changed files with 3 additions and 0 deletions
|
|
@ -54,6 +54,9 @@ export const llmSetupStatusAtomFamily = atomFamily((workspaceId: number) =>
|
|||
queryKey: cacheKeys.modelConnections.setupStatus(workspaceId),
|
||||
enabled: workspaceId > 0 && isAuthenticated(),
|
||||
staleTime: 5 * 60 * 1000,
|
||||
// Recovery is event-driven: mutations invalidate this key; external fixes
|
||||
// are caught on window focus. No polling, so not-ready tabs cost nothing.
|
||||
refetchOnWindowFocus: true,
|
||||
queryFn: () => modelConnectionsApiService.getLlmSetupStatus(workspaceId),
|
||||
}))
|
||||
);
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue