@iamcalegari/mongoat / OnHookError
Type Alias: OnHookError<Ctx>
OnHookError<
Ctx> = (err,ctx) =>void
Defined in: src/types/hooks.ts:57
Callback invoked when a fireAndForget post-hook rejects. err is typed unknown — third-party hooks can throw anything, not necessarily a MongoatError/Error. Receives the SAME ctx the hook itself received (result/document/filter included) — the consumer of onHookError is responsible for not logging sensitive fields without redaction.
Type Parameters
Ctx
Ctx
Parameters
err
unknown
ctx
Ctx
Returns
void