Skip to content

Commit

Permalink
Merge pull request #110 from IT4Change/disable-103-earlyhints
Browse files Browse the repository at this point in the history
fix(frontend): disable 103 early hints
  • Loading branch information
ulfgebhardt authored Mar 14, 2024
2 parents 9cf9ff7 + 29e7be7 commit 40face5
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion server/index.ts
Original file line number Diff line number Diff line change
Expand Up @@ -80,7 +80,7 @@ async function startServer() {
next()
} else {
const { body, statusCode, headers, earlyHints } = httpResponse
if (res.writeEarlyHints)
if (process.env.EARLY_HINTS && res.writeEarlyHints)
res.writeEarlyHints({ link: earlyHints.map((e) => e.earlyHintLink) })
headers.forEach(([name, value]) => res.setHeader(name, value))
res.status(statusCode)
Expand Down

0 comments on commit 40face5

Please sign in to comment.