Skip to content

Commit 3502268

Browse files
committed
Remove useless check of attributes existence
1 parent 02cafa3 commit 3502268

File tree

1 file changed

+1
-5
lines changed

1 file changed

+1
-5
lines changed

src/hooks.server.js

Lines changed: 1 addition & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -33,11 +33,7 @@ export async function handleFetch({ event, request, fetch }) {
3333
2. https://kit.svelte.dev/docs/hooks#server-hooks-handlefetch
3434
*/
3535

36-
if (
37-
request.url.startsWith(FRACTAL_SERVER_HOST) &&
38-
'headers' in request &&
39-
'cookie' in request.headers
40-
) {
36+
if (request.url.startsWith(FRACTAL_SERVER_HOST)) {
4137
console.log(`Including cookie into request to ${request.url}, via handleFetch`);
4238
request.headers.set('cookie', event.request.headers.get('cookie'));
4339
}

0 commit comments

Comments
 (0)