File tree Expand file tree Collapse file tree 2 files changed +2
-10
lines changed Expand file tree Collapse file tree 2 files changed +2
-10
lines changed Original file line number Diff line number Diff line change @@ -131,7 +131,7 @@ export default async (
131131 } )
132132 }
133133
134- setCacheControlHeaders ( response , request , requestContext , nextConfig )
134+ setCacheControlHeaders ( response , request , requestContext )
135135 setCacheTagsHeaders ( response . headers , requestContext )
136136 setVaryHeaders ( response . headers , request , nextConfig )
137137 setCacheStatusHeader ( response . headers , nextCache )
Original file line number Diff line number Diff line change @@ -3,7 +3,7 @@ import type { NextConfigComplete } from 'next/dist/server/config-shared.js'
33
44import type { NetlifyCachedRouteValue , NetlifyCacheHandlerValue } from '../shared/cache-types.cjs'
55
6- import { getLogger , RequestContext } from './handlers/request-context.cjs'
6+ import { RequestContext } from './handlers/request-context.cjs'
77import { recordWarning } from './handlers/tracer.cjs'
88import { getMemoizedKeyValueStoreBackedByRegionalBlobStore } from './storage/storage.cjs'
99
@@ -200,7 +200,6 @@ export const setCacheControlHeaders = (
200200 { headers, status } : Response ,
201201 request : Request ,
202202 requestContext : RequestContext ,
203- nextConfig : NextConfigComplete ,
204203) => {
205204 if (
206205 typeof requestContext . routeHandlerRevalidate !== 'undefined' &&
@@ -213,13 +212,6 @@ export const setCacheControlHeaders = (
213212 return
214213 }
215214
216- // temporary diagnostic to evaluate number of trailing slash redirects
217- if ( status === 308 && request . url . endsWith ( '/' ) !== nextConfig . trailingSlash ) {
218- getLogger ( )
219- . withFields ( { trailingSlash : nextConfig . trailingSlash , location : headers . get ( 'location' ) } )
220- . log ( 'NetlifyHeadersHandler.trailingSlashRedirect' )
221- }
222-
223215 const cacheControl = headers . get ( 'cache-control' )
224216 if ( status === 404 ) {
225217 if ( request . url . endsWith ( '.php' ) ) {
You can’t perform that action at this time.
0 commit comments