Skip to content

Commit 9fdd493

Browse files
committed
fix: skip ever trying to run middleware in lambda
1 parent 674f0f7 commit 9fdd493

File tree

1 file changed

+8
-0
lines changed

1 file changed

+8
-0
lines changed

packages/runtime/src/templates/server.ts

+8
Original file line numberDiff line numberDiff line change
@@ -18,6 +18,7 @@ interface NetlifyConfig {
1818
revalidateToken?: string
1919
}
2020

21+
// eslint-disable-next-line max-lines-per-function
2122
const getNetlifyNextServer = (NextServer: NextServerType) => {
2223
class NetlifyNextServer extends NextServer {
2324
private netlifyConfig: NetlifyConfig
@@ -118,6 +119,13 @@ const getNetlifyNextServer = (NextServer: NextServerType) => {
118119
}
119120
}
120121

122+
// eslint-disable-next-line class-methods-use-this, require-await
123+
async runMiddleware(): Promise<{ finished: boolean }> {
124+
return {
125+
finished: false,
126+
}
127+
}
128+
121129
private getNetlifyPathsForRoute(route: string): string[] {
122130
const { i18n } = this.nextConfig
123131
const { routes, dynamicRoutes } = this.netlifyPrerenderManifest

0 commit comments

Comments
 (0)