From fca9315a805c02dd7c0bb2726759b92fb0e8b0b4 Mon Sep 17 00:00:00 2001 From: Idan Gazit Date: Tue, 27 Aug 2024 15:32:34 -0700 Subject: [PATCH] More max-age limit testing --- src/hooks.server.ts | 2 +- src/routes/+page.server.ts | 2 +- 2 files changed, 2 insertions(+), 2 deletions(-) diff --git a/src/hooks.server.ts b/src/hooks.server.ts index 2f34e56..0b14fd5 100644 --- a/src/hooks.server.ts +++ b/src/hooks.server.ts @@ -6,7 +6,7 @@ export const handle: Handle = async ({ event, resolve }) => { event.setHeaders({ 'X-My-Path-Is': event.url.pathname }); event.cookies.set('testcookie', 'testcookie', { path: '/', - maxAge: 3153699999, + maxAge: 3153600001, }); event.setHeaders({'X-All-The-Cookies': JSON.stringify(event.cookies.getAll())}); diff --git a/src/routes/+page.server.ts b/src/routes/+page.server.ts index 51077b0..912357b 100644 --- a/src/routes/+page.server.ts +++ b/src/routes/+page.server.ts @@ -2,5 +2,5 @@ import type { PageServerLoad } from './$types'; export const load: PageServerLoad = async ({cookies}) => { console.log('SvelteKit load function processed a request.'); - cookies.set('pagecookiename', 'pagecookievalue', {'path': '/', maxAge: 3153699999}); + cookies.set('pagecookiename', 'pagecookievalue', {'path': '/', maxAge: 3153600000}); } \ No newline at end of file