2
1
mirror of https://github.com/Thream/socketio-jwt.git synced 2024-07-21 09:38:31 +02:00

fix(types): onAuthorization can return a string

This commit is contained in:
Divlo 2021-07-23 22:54:07 +02:00
parent 15f5c60b27
commit a41881744a
No known key found for this signature in database
GPG Key ID: 6F24DA54DA3967CF

View File

@ -30,7 +30,7 @@ interface CompleteDecodedToken {
payload: any
}
type SecretCallback = (decodedToken: CompleteDecodedToken) => Promise<string>
type SecretCallback = (decodedToken: CompleteDecodedToken) => Promise<string> | string
export interface AuthorizeOptions {
secret: string | SecretCallback