Setting cache-control header for icon routes results in duplicate header values #70086
Labels
bug
Issue was opened via the bug report template.
Middleware
Related to Next.js Middleware.
Runtime
Related to Node.js or Edge Runtime with Next.js.
Link to the code that reproduces this issue
https://codesandbox.io/p/devbox/quirky-bassi-x3nw3t
To Reproduce
cache-control
header is being overriddenCurrent vs. Expected behavior
Expected:
cache-control: max-age=1234
Actual:
cache-control: max-age=1234, public, max-age=0, must-revalidate
Provide environment information
Operating System: Platform: linux Arch: x64 Version: #1 SMP PREEMPT_DYNAMIC Sun Aug 6 20:05:33 UTC 2023 Available memory (MB): 4102 Available CPU cores: 2 Binaries: Node: 20.9.0 npm: 9.8.1 Yarn: 1.22.19 pnpm: 8.10.2 Relevant Packages: next: 15.0.0-canary.154 // Latest available version is detected (15.0.0-canary.154). eslint-config-next: N/A react: 19.0.0-rc-94e652d5-20240912 react-dom: 19.0.0-rc-94e652d5-20240912 typescript: 5.3.3 Next.js Config: output: N/A
Which area(s) are affected? (Select all that apply)
Middleware, Runtime
Which stage(s) are affected? (Select all that apply)
next dev (local), next build (local), next start (local), Other (Deployed)
Additional context
Overriding the cache-control header in middleware.ts has the same result. This only seems to happen to icons.
The text was updated successfully, but these errors were encountered: