mirror of
https://github.com/wassname/DefinitelyTyped.git
synced 2026-09-09 11:13:57 +08:00
Add support for 'passReqToCallback' to passport-local
When 'passReqToCallback' is true, 'req' will be passed as the first argument to the verify callback.
This commit is contained in:
Vendored
+2
@@ -13,6 +13,7 @@ declare module 'passport-local' {
|
||||
interface IStrategyOptions {
|
||||
usernameField?: string;
|
||||
passwordField?: string;
|
||||
passReqToCallback?: boolean;
|
||||
}
|
||||
|
||||
interface IVerifyOptions {
|
||||
@@ -20,6 +21,7 @@ declare module 'passport-local' {
|
||||
}
|
||||
|
||||
interface VerifyFunction {
|
||||
(req: express.Request, username: string, password: string, done: (error: any, user?: any, options?: IVerifyOptions) => void): void;
|
||||
(username: string, password: string, done: (error: any, user?: any, options?: IVerifyOptions) => void): void;
|
||||
}
|
||||
|
||||
|
||||
Reference in New Issue
Block a user