Skip to content

Commit

Permalink
Update packages/next/export/worker.ts
Browse files Browse the repository at this point in the history
Co-authored-by: JJ Kasper <jj@jjsweb.site>
  • Loading branch information
huozhi and ijjk authored Dec 13, 2021
1 parent 668a33d commit 45734b8
Showing 1 changed file with 2 additions and 0 deletions.
2 changes: 2 additions & 0 deletions packages/next/export/worker.ts
Original file line number Diff line number Diff line change
Expand Up @@ -215,6 +215,8 @@ export default async function exportPage({
subFolders ? `${_path}${sep}index.html` : `${_path}.html`
let htmlFilename = getHtmlFilename(filePath)

// dynamic routes can provide invalid extensions e.g. /blog/[...slug] returns an
// extension of `.slug]`
const pageExt = isDynamic ? '' : extname(page)
const pathExt = isDynamic ? '' : extname(path)
// Make sure page isn't a folder with a dot in the name e.g. `v1.2`
Expand Down

0 comments on commit 45734b8

Please sign in to comment.