Skip to content

Commit

Permalink
Merge branch 'canary' into fix/imgix-no-double-querystrings
Browse files Browse the repository at this point in the history
  • Loading branch information
kodiakhq[bot] authored Jul 6, 2021
2 parents 5299aef + 2795b79 commit 0d8173e
Show file tree
Hide file tree
Showing 3 changed files with 156 additions and 68 deletions.
7 changes: 4 additions & 3 deletions packages/next/server/dev/next-dev-server.ts
Original file line number Diff line number Diff line change
Expand Up @@ -30,6 +30,7 @@ import Server, {
WrappedBuildError,
ServerConstructor,
FindComponentsResult,
ResponsePayload,
} from '../next-server'
import { normalizePagePath } from '../normalize-page-path'
import Router, { Params, route } from '../router'
Expand Down Expand Up @@ -636,14 +637,14 @@ export default class DevServer extends Server {
return await loadDefaultErrorComponents(this.distDir)
}

sendHTML(
sendResponse(
req: IncomingMessage,
res: ServerResponse,
html: string
response: ResponsePayload
): Promise<void> {
// In dev, we should not cache pages for any reason.
res.setHeader('Cache-Control', 'no-store, must-revalidate')
return super.sendHTML(req, res, html)
return super.sendResponse(req, res, response)
}

protected setImmutableAssetCacheControl(res: ServerResponse): void {
Expand Down
Loading

0 comments on commit 0d8173e

Please sign in to comment.