From 9c22a51d790c0161da041313a1dc488602908daa Mon Sep 17 00:00:00 2001 From: pilcrowOnPaper Date: Sun, 13 Oct 2024 00:41:45 +0900 Subject: [PATCH] fix typo --- pages/sessions/cookies/sveltekit.md | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/pages/sessions/cookies/sveltekit.md b/pages/sessions/cookies/sveltekit.md index 0c32233..eeb3702 100644 --- a/pages/sessions/cookies/sveltekit.md +++ b/pages/sessions/cookies/sveltekit.md @@ -28,7 +28,7 @@ import type { RequestEvent } from "@sveltejs/kit"; // ... export function setSessionTokenCookie(event: RequestEvent, token: string, expiresAt: Date): void { - context.cookies.set("session", token, { + event.cookies.set("session", token, { httpOnly: true, sameSite: "lax", expires: expiresAt, @@ -37,7 +37,7 @@ export function setSessionTokenCookie(event: RequestEvent, token: string, expire } export function deleteSessionTokenCookie(event: RequestEvent): void { - context.cookies.set("session", "", { + event.cookies.set("session", "", { httpOnly: true, sameSite: "lax", maxAge: 0,