1
Fork 0

Refactor conditional

This commit is contained in:
Eliaz Bobadilla 2022-02-04 14:59:22 -05:00
parent cb18e83e85
commit ca4296dcfe

View file

@ -587,11 +587,8 @@ window.initSearch = function(rawSearchIndex) {
}
function typePassesFilter(filter, type) {
// No filter
if (filter <= NO_TYPE_FILTER) return true;
// Exact match
if (filter === type) return true;
// No filter or Exact mach
if (filter <= NO_TYPE_FILTER || filter === type) return true;
// Match related items
var name = itemTypes[type];