Properly escape file names for HTML exoprt
All checks were successful
continuous-integration/drone/push Build is passing
continuous-integration/drone Build is passing

This commit is contained in:
Garrett Mills 2020-10-19 08:07:36 -05:00
parent 7316b87f62
commit c7f14ecb3a
Signed by: garrettmills
GPG Key ID: D2BF5FBA8298F246

View File

@ -78,7 +78,7 @@ class ExportController extends Controller {
flat_tree.push({
level,
page,
file_name: `${page.Name.replace(/\s/g, '-')}-${page.UUID}.html`,
file_name: `${page.Name.replace(/\s/g, '-').replace(/\/\\/g, '-')}-${page.UUID}.html`,
})
const children = await page.childPages