hotfix: update edge.js to fix sitemap.xml routing

pull/3189/head
Scott Anderson 2021-09-29 17:10:55 -06:00 committed by GitHub
parent 1b5de3f3b3
commit 99b53d3dfa
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23
1 changed files with 1 additions and 1 deletions

View File

@ -180,7 +180,7 @@ exports.handler = (event, context, callback) => {
// or if the version number is parsed as an extension.
let newUri;
if (parsedPath.ext === '' || /\.[x0-9]{1,}/.test(parsedPath.ext)) {
if (parsedPath.ext === '' || /\.(?:x$|[0-9]{1,})/.test(parsedPath.ext)) {
newUri = path.join(parsedPath.dir, parsedPath.base, indexPath);
} else {
newUri = request.uri;