Skip to content

Commit

Permalink
fix(ts): fall back to empty string when parsing cookie
Browse files Browse the repository at this point in the history
  • Loading branch information
balazsorban44 committed Jul 1, 2022
1 parent cd6ccfd commit 5319dca
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion packages/next-auth/src/core/index.ts
Expand Up @@ -69,7 +69,7 @@ async function toInternalRequest(
method: req.method,
headers,
body: await getBody(req),
cookies: parseCookie(req.headers.get("cookie")),
cookies: parseCookie(req.headers.get("cookie") ?? ""),
providerId: nextauth[1],
error: url.searchParams.get("error") ?? nextauth[1],
host: detectHost(headers["x-forwarded-host"] ?? headers.host),
Expand Down

0 comments on commit 5319dca

Please sign in to comment.