From 6394e16a45ec49b8919ed6e0522bff85f27f2cf3 Mon Sep 17 00:00:00 2001 From: Alessio Davoli Date: Fri, 22 Dec 2023 13:20:49 +0100 Subject: [PATCH] Use sveltekit fetch instead of window.fetch --- frontend/src/hooks.server.ts | 4 ++++ 1 file changed, 4 insertions(+) diff --git a/frontend/src/hooks.server.ts b/frontend/src/hooks.server.ts index 6736b1d..0e702e0 100644 --- a/frontend/src/hooks.server.ts +++ b/frontend/src/hooks.server.ts @@ -3,6 +3,10 @@ export async function handle({ event, resolve }) { return response; } +export async function handleFetch({ request, fetch }) { + return fetch(request); +} + export async function handleError({ error, event, status, message }) { console.error(error) return {