Skip to content

Commit

Permalink
fix: mdn#6278 for when HTML file are removed/redirected / boolean logic
Browse files Browse the repository at this point in the history
  • Loading branch information
SphinxKnight committed May 15, 2022
1 parent 8f248fb commit 761c752
Showing 1 changed file with 2 additions and 3 deletions.
5 changes: 2 additions & 3 deletions content/document.js
Original file line number Diff line number Diff line change
Expand Up @@ -509,9 +509,8 @@ function findChildren(url, recursive = false) {
.withErrors()
.filter((filePath) => {
return (
filePath.endsWith(HTML_FILENAME) ||
(filePath.endsWith(MARKDOWN_FILENAME) &&
!(filePath === baseHTML || filePath === baseMarkdown))
(filePath.endsWith(HTML_FILENAME) && !(filePath === baseHTML)) ||
(filePath.endsWith(MARKDOWN_FILENAME) && !(filePath === baseMarkdown))
);
})
.withMaxDepth(recursive ? Infinity : 1)
Expand Down

0 comments on commit 761c752

Please sign in to comment.