mirror of
https://github.com/gosticks/DefinitelyTyped.git
synced 2026-10-04 14:57:10 +00:00
combine possible error types in single type and use it for verification callback (#26853)
This commit is contained in:
committed by
Mohamed Hegazy
parent
24aa1a07b7
commit
4bb84f6a19
Vendored
+2
-2
@@ -77,10 +77,10 @@ export interface DecodeOptions {
|
||||
complete?: boolean;
|
||||
json?: boolean;
|
||||
}
|
||||
|
||||
export type VerifyErrors=JsonWebTokenError | NotBeforeError | TokenExpiredError;
|
||||
export interface VerifyCallback {
|
||||
(
|
||||
err: JsonWebTokenError | NotBeforeError | TokenExpiredError,
|
||||
err: VerifyErrors,
|
||||
decoded: object | string,
|
||||
): void;
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user