We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
There was an error while loading. Please reload this page.
1 parent 5848fab commit 9f6c992Copy full SHA for 9f6c992
src/core/mutation.ts
@@ -178,7 +178,7 @@ export class Mutation<
178
this.options.onSuccess?.(
179
data,
180
this.state.variables!,
181
- this.state.context!
+ this.state.context
182
)
183
184
.then(() =>
src/core/types.ts
@@ -548,7 +548,7 @@ export interface MutationOptions<
548
onSuccess?: (
549
data: TData,
550
variables: TVariables,
551
- context: TContext
+ context: TContext | undefined
552
) => Promise<unknown> | void
553
onError?: (
554
error: TError,
0 commit comments