mirror of
https://github.com/pacnpal/thrilltrack-explorer.git
synced 2025-12-23 14:11:13 -05:00
Fix edge function logging and types
This commit is contained in:
@@ -83,12 +83,15 @@ const queryClient = new QueryClient({
|
||||
gcTime: 5 * 60 * 1000, // 5 minutes - keep in cache for 5 mins
|
||||
},
|
||||
mutations: {
|
||||
onError: (error: any, variables: any, context: any) => {
|
||||
onError: (error: unknown, variables: unknown, context: unknown) => {
|
||||
// Track mutation errors with breadcrumbs
|
||||
const contextObj = context as { endpoint?: string } | undefined;
|
||||
const errorObj = error as { status?: number } | undefined;
|
||||
|
||||
breadcrumb.apiCall(
|
||||
context?.endpoint || 'mutation',
|
||||
contextObj?.endpoint || 'mutation',
|
||||
'MUTATION',
|
||||
error?.status || 500
|
||||
errorObj?.status || 500
|
||||
);
|
||||
|
||||
// Handle error with tracking
|
||||
|
||||
Reference in New Issue
Block a user