MCPcopy Create free account
hub / github.com/Kilo-Org/cloud / useTriggerStatsUpdate

Function useTriggerStatsUpdate

apps/web/src/app/admin/api/model-stats/hooks.ts:62–73  ·  view source on GitHub ↗
()

Source from the content-addressed store, hash-verified

60}
61
62export function useTriggerStatsUpdate() {
63 const trpc = useTRPC();
64 const queryClient = useQueryClient();
65
66 return useMutation(
67 trpc.admin.modelStats.triggerSync.mutationOptions({
68 onSuccess: () => {
69 void queryClient.invalidateQueries({ queryKey: [['admin', 'modelStats', 'list']] });
70 },
71 })
72 );
73}
74
75export function useBustModelStatsCache() {
76 const trpc = useTRPC();

Callers 1

ModelStatsTableFunction · 0.90

Calls

no outgoing calls

Tested by

no test coverage detected