Skip to content

Commit 6316c28

Browse files
authored
Merge pull request #1439 from dhalbert/search-ignore-hyphens
match hyphenated or unhyphenated search terms
2 parents 1d58cab + b90a982 commit 6316c28

1 file changed

Lines changed: 3 additions & 1 deletion

File tree

assets/javascript/downloads.js

Lines changed: 3 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -419,7 +419,9 @@ function shouldDisplayDownload(download, displayedManufacturers, displayedMcufam
419419

420420

421421
for (const term of downloadsSearch.searchTerm.toLowerCase().split(" ")) {
422-
if (!downloadData.includes(term)) {
422+
if (!
423+
(downloadData.includes(term) ||
424+
downloadData.includes(term.replaceAll("-", "")))) {
423425
return false;
424426
}
425427
}

0 commit comments

Comments
 (0)