diff --git a/packages/auth-providers/dbAuth/api/src/shared.ts b/packages/auth-providers/dbAuth/api/src/shared.ts index 2ef2dc00cd96..f4f0451dbe94 100644 --- a/packages/auth-providers/dbAuth/api/src/shared.ts +++ b/packages/auth-providers/dbAuth/api/src/shared.ts @@ -191,18 +191,12 @@ export const dbAuthSession = ( cookieNameOption: string | undefined ) => { const sessionCookie = extractCookie(event) - const bearerToken = extractEncryptedSessionFromHeader(event) if (sessionCookie) { // i.e. Browser making a request const [session, _csrfToken] = decryptSession( getSession(sessionCookie, cookieNameOption) ) - return session - } else if (bearerToken) { - // i.e. FE Sever makes the request, and adds encrypted session to the Authorization header - const [session, _csrfToken] = decryptSession(bearerToken) - return session } else { return null