mirror of
https://github.com/terribleplan/next.js.git
synced 2024-01-19 02:48:18 +00:00
Set Cache-Control max-age to a year (#3247)
This commit is contained in:
parent
629d0a261b
commit
dc07cd1b19
|
@ -417,7 +417,7 @@ export default class Server {
|
|||
return false
|
||||
}
|
||||
|
||||
res.setHeader('Cache-Control', 'max-age=365000000, immutable')
|
||||
res.setHeader('Cache-Control', 'max-age=31536000, immutable')
|
||||
return true
|
||||
}
|
||||
|
||||
|
@ -441,7 +441,7 @@ export default class Server {
|
|||
throw new Error(`Invalid Build File Hash(${hash}) for chunk: ${filename}`)
|
||||
}
|
||||
|
||||
res.setHeader('Cache-Control', 'max-age=365000000, immutable')
|
||||
res.setHeader('Cache-Control', 'max-age=31536000, immutable')
|
||||
return true
|
||||
}
|
||||
|
||||
|
|
Loading…
Reference in a new issue