File tree 1 file changed +10
-2
lines changed
1 file changed +10
-2
lines changed Original file line number Diff line number Diff line change @@ -331,13 +331,21 @@ const baseServerReplacements: Array<[string, string]> = [
331
331
332
332
const nextServerReplacements : Array < [ string , string ] > = [
333
333
[
334
- `getMiddlewareManifest() {\n if (!this.minimalMode) {` ,
335
- `getMiddlewareManifest() {\n if (!this.minimalMode && !process.env.NEXT_USE_NETLIFY_EDGE) {` ,
334
+ `getMiddlewareManifest() {\n if (this.minimalMode) return null;` ,
335
+ `getMiddlewareManifest() {\n if (this.minimalMode || process.env.NEXT_USE_NETLIFY_EDGE) return null;` ,
336
+ ] ,
337
+ [
338
+ `generateCatchAllMiddlewareRoute(devReady) {\n if (this.minimalMode) return []` ,
339
+ `generateCatchAllMiddlewareRoute(devReady) {\n if (this.minimalMode || process.env.NEXT_USE_NETLIFY_EDGE) return [];` ,
336
340
] ,
337
341
[
338
342
`generateCatchAllMiddlewareRoute() {\n if (this.minimalMode) return undefined;` ,
339
343
`generateCatchAllMiddlewareRoute() {\n if (this.minimalMode || process.env.NEXT_USE_NETLIFY_EDGE) return undefined;` ,
340
344
] ,
345
+ [
346
+ `getMiddlewareManifest() {\n if (this.minimalMode) {` ,
347
+ `getMiddlewareManifest() {\n if (!this.minimalMode && !process.env.NEXT_USE_NETLIFY_EDGE) {` ,
348
+ ] ,
341
349
]
342
350
343
351
export const patchNextFiles = async ( root : string ) : Promise < void > => {
You can’t perform that action at this time.
0 commit comments