You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Copy file name to clipboardExpand all lines: Readme.md
+2-1Lines changed: 2 additions & 1 deletion
Display the source diff
Display the rich diff
Original file line number
Diff line number
Diff line change
@@ -82,7 +82,8 @@ Defaults to `rfc6750`.
82
82
*`addHook`: If `false`, this plugin will not register `onRequest` hook automatically.
83
83
Instead it provides two decorations: `fastify.verifyBearerAuth` and
84
84
`fastify.verifyBearerAuthFactory`
85
-
*`hook`: Specify the hook to register the plugin, accepts `onRequest` or `preParsing`. Defaults to `onRequest` (optional)
85
+
*`addHook`: If `false`, this plugin will not register any hook automatically. Instead, it provides two decorations: `fastify.verifyBearerAuth` and
86
+
`fastify.verifyBearerAuthFactory`. If `true` or nullish, it will default to `onRequest`. You can also specify `onRequest` or `preParsing` to register the respective hook
86
87
*`verifyErrorLogLevel`: An optional string specifying the log level for verification errors.
87
88
It must be a valid log level supported by Fastify, or an exception will be thrown when
88
89
registering the plugin. By default, this option is set to `error`
0 commit comments