Commit c2a7766a authored by Tim Neutkens's avatar Tim Neutkens Committed by Leo Lamprecht

Remove code that is no longer in use (#5147)

* Remove handleBuildId as it’s being handled in the static files route

* Remove dead code
parent 344d770a
...@@ -352,20 +352,6 @@ export default class Server { ...@@ -352,20 +352,6 @@ export default class Server {
return buildId.trim() return buildId.trim()
} }
handleBuildId (buildId, res) {
if (this.dev) {
res.setHeader('Cache-Control', 'no-store, must-revalidate')
return true
}
if (buildId !== this.renderOpts.buildId) {
return false
}
res.setHeader('Cache-Control', 'public, max-age=31536000, immutable')
return true
}
async getCompilationError (page) { async getCompilationError (page) {
if (!this.hotReloader) return if (!this.hotReloader) return
...@@ -375,9 +361,4 @@ export default class Server { ...@@ -375,9 +361,4 @@ export default class Server {
// Return the very first error we found. // Return the very first error we found.
return errors[0] return errors[0]
} }
send404 (res) {
res.statusCode = 404
res.end('404 - Not Found')
}
} }
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment