Skip to content

Commit 6168379

Browse files
authored
repo sync
2 parents 58be1ea + 218ac32 commit 6168379

1 file changed

Lines changed: 2 additions & 4 deletions

File tree

lib/site-tree.js

Lines changed: 2 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -37,8 +37,6 @@ module.exports = async function buildSiteTree (pageMap, site, redirects) {
3737
return
3838
}
3939

40-
product.href = path.posix.join('/', languageCode, item.href)
41-
4240
// find the product TOC page so we have access to the TOC items
4341
const page = findPage(item.href, pageMap, redirects)
4442

@@ -47,9 +45,9 @@ module.exports = async function buildSiteTree (pageMap, site, redirects) {
4745
if (!getApplicableVersions(page.versions).includes(version)) return
4846

4947
// item.hrefs have a default version via lib/all-products, so update to the current version
50-
const versionedProductHref = removeFPTFromPath(path.join('/', languageCode, version, getPathWithoutVersion(item.href)))
48+
product.href = removeFPTFromPath(path.join('/', languageCode, version, getPathWithoutVersion(item.href)))
5149

52-
product.categories = buildCategoriesTree(page.tocItems, versionedProductHref, pageMap, redirects, version)
50+
product.categories = buildCategoriesTree(page.tocItems, product.href, pageMap, redirects, version)
5351

5452
productTree[item.id] = product
5553
return null

0 commit comments

Comments
 (0)