Skip to content

Commit 18b14d7

Browse files
committed
Don't run findPagesDir in production mode
1 parent 4e1f113 commit 18b14d7

File tree

1 file changed

+1
-2
lines changed

1 file changed

+1
-2
lines changed

packages/next/next-server/server/next-server.ts

Lines changed: 1 addition & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -66,7 +66,7 @@ export default class Server {
6666
quiet: boolean
6767
nextConfig: NextConfig
6868
distDir: string
69-
pagesDir: string
69+
pagesDir?: string
7070
publicDir: string
7171
pagesManifest: string
7272
buildId: string
@@ -97,7 +97,6 @@ export default class Server {
9797
this.dir = resolve(dir)
9898
this.quiet = quiet
9999
const phase = this.currentPhase()
100-
this.pagesDir = findPagesDir(this.dir)
101100
this.nextConfig = loadConfig(phase, this.dir, conf)
102101
this.distDir = join(this.dir, this.nextConfig.distDir)
103102
this.publicDir = join(this.dir, CLIENT_PUBLIC_FILES_PATH)

0 commit comments

Comments
 (0)