mirror of
https://github.com/MBombeck/HealthLog.git
synced 2026-11-13 22:32:04 +00:00
style(insights): prettier sweep on C1 + C2 wire-up files
Co-Authored-By: Claude Opus 4.7 (1M context) <noreply@anthropic.com>
This commit is contained in:
1 parent
8a5b6de27e
commit
c63cddc6dd
3 files changed
+10
-9
No files matched your search
@@ -63,7 +63,9 @@ export interface UseInsightsAdvisorResult {
|
||||
* Read-only consumer for the advisor payload. Use this on surfaces that
|
||||
* just want to render the cached insight (e.g. dashboard preview).
|
||||
*/
|
||||
export function useInsightsAdvisorQuery(enabled: boolean): UseInsightsAdvisorResult {
|
||||
export function useInsightsAdvisorQuery(
|
||||
enabled: boolean,
|
||||
): UseInsightsAdvisorResult {
|
||||
const queryClient = useQueryClient();
|
||||
const query = useQuery({
|
||||
queryKey: queryKeys.insightsAdvisor(),
|
||||
@@ -80,7 +82,9 @@ export function useInsightsAdvisorQuery(enabled: boolean): UseInsightsAdvisorRes
|
||||
if (next) {
|
||||
queryClient.setQueryData(queryKeys.insightsAdvisor(), next);
|
||||
} else {
|
||||
queryClient.invalidateQueries({ queryKey: queryKeys.insightsAdvisor() });
|
||||
queryClient.invalidateQueries({
|
||||
queryKey: queryKeys.insightsAdvisor(),
|
||||
});
|
||||
}
|
||||
// Per-status caches are evicted server-side on regenerate; refresh
|
||||
// their query subtree so the per-section text below the advisor card
|
||||
|
||||
Reference in new issue
Block a user