未验证 提交 7d5556a5 编写于 作者: J JJ Kasper 提交者: GitHub

Fix serverDir resolving for autoExporting (#7504)

上级 02551d3b
......@@ -381,7 +381,9 @@ export default async function build(dir: string, conf = null): Promise<void> {
// remove server bundles that were exported
for (const page of staticPages) {
const { serverBundle } = pageInfos.get(page)!
if (!serverDir) serverDir = path.dirname(serverBundle)
if (!serverDir) {
serverDir = path.join(serverBundle.split(/\/pages/).shift()!, 'pages')
}
await fsUnlink(serverBundle)
}
......
Markdown is supported
0% .
You are about to add 0 people to the discussion. Proceed with caution.
先完成此消息的编辑!
想要评论请 注册