Skip to content

Commit

Permalink
fix code
Browse files Browse the repository at this point in the history
  • Loading branch information
pilcrowonpaper committed Oct 7, 2024
1 parent 7cc63a1 commit a8b1629
Showing 1 changed file with 2 additions and 2 deletions.
4 changes: 2 additions & 2 deletions pages/tutorials/github-oauth/nextjs.md
Original file line number Diff line number Diff line change
Expand Up @@ -165,8 +165,8 @@ export async function GET(request: Request): Promise<Response> {
// TODO: Replace this with your own DB query.
const user = await createUser(githubUserId, githubUsername);

const sessionToken = generateSessionToken();
const session = await createSession(sessionToken, user.id);
const token = generateSessionToken();
const session = await createSession(token, user.id);
setSessionTokenCookie(token, session.expiresAt);
return new Response(null, {
status: 302,
Expand Down

0 comments on commit a8b1629

Please sign in to comment.