From c9990e9d3096d88355ff22a66083a3997e93f1f7 Mon Sep 17 00:00:00 2001 From: Valentin Brandl Date: Wed, 28 Aug 2024 16:12:38 +0200 Subject: [PATCH] Simplify --- src/hooks.server.ts | 6 +++--- src/{ => lib}/index.test.ts | 0 2 files changed, 3 insertions(+), 3 deletions(-) rename src/{ => lib}/index.test.ts (100%) diff --git a/src/hooks.server.ts b/src/hooks.server.ts index 17372c1..dc43d27 100644 --- a/src/hooks.server.ts +++ b/src/hooks.server.ts @@ -24,9 +24,9 @@ export const handle: Handle = async ({ event, resolve }) => { // make requestId available to handlers event.locals.requestId = requestId; - const { executionTime, result: response } = await timedExecution(async () => { - return await resolve(event); - }); + const { executionTime, result: response } = await timedExecution( + async () => await resolve(event) + ); response.headers.set(requestIdHeader, requestId); log.info( diff --git a/src/index.test.ts b/src/lib/index.test.ts similarity index 100% rename from src/index.test.ts rename to src/lib/index.test.ts