Broaden type in authenticate as undefined is also nullable

This commit is contained in:
Michcio 2022-09-25 17:20:44 +02:00
parent 0120dee999
commit 71f339b23a

View file

@ -15,7 +15,7 @@ export class AuthenticationError extends Error {
}
}
export default async (authorization: string | null | undefined, bodyToken: string | null): Promise<[CacheableLocalUser | null | undefined, AccessToken | null | undefined]> => {
export default async (authorization: string | null | undefined, bodyToken: string | null | undefined): Promise<[CacheableLocalUser | null | undefined, AccessToken | null | undefined]> => {
let token: string | null = null;
// check if there is an authorization header set