mirror of
https://github.com/terribleplan/next.js.git
synced 2024-01-19 02:48:18 +00:00
feat: error when exported path has no backslash (#3456)
This commit is contained in:
parent
702dd5d3f4
commit
a3aa870b74
|
@ -91,6 +91,9 @@ export default async function (dir, options, configuration) {
|
||||||
|
|
||||||
for (const path of exportPaths) {
|
for (const path of exportPaths) {
|
||||||
log(` exporting path: ${path}`)
|
log(` exporting path: ${path}`)
|
||||||
|
if (!path.startsWith('/')) {
|
||||||
|
throw new Error(`path "${path}" doesn't start with a backslash`)
|
||||||
|
}
|
||||||
|
|
||||||
const { page, query = {} } = exportPathMap[path]
|
const { page, query = {} } = exportPathMap[path]
|
||||||
const req = { url: path }
|
const req = { url: path }
|
||||||
|
|
Loading…
Reference in a new issue