Skip to content

Commit

Permalink
fix default hook
Browse files Browse the repository at this point in the history
  • Loading branch information
Alexander Konstantinov committed Nov 16, 2024
1 parent 5289247 commit fd066e6
Showing 1 changed file with 2 additions and 2 deletions.
4 changes: 2 additions & 2 deletions packages/kit/src/runtime/server/index.js
Original file line number Diff line number Diff line change
Expand Up @@ -69,7 +69,7 @@ export class Server {

this.#options.hooks = {
handle: module.handle || (({ event, resolve }) => resolve(event)),
handlePageData: module.handlePageData || (({ pageData, resolve }) => resolve(pageData)),
handlePageData: module.handlePageData || (() => void null),
handleError: module.handleError || (({ error }) => console.error(error)),
handleFetch: module.handleFetch || (({ request, fetch }) => fetch(request)),
reroute: module.reroute || (() => {})
Expand All @@ -80,7 +80,7 @@ export class Server {
handle: () => {
throw error;
},
handlePageData: ({ pageData, resolve }) => resolve(pageData),
handlePageData: () => void null,
handleError: ({ error }) => console.error(error),
handleFetch: ({ request, fetch }) => fetch(request),
reroute: () => {}
Expand Down

0 comments on commit fd066e6

Please sign in to comment.