Skip to content

Commit

Permalink
Merge pull request #510 from mlibrary/academic-discipline-hierarchy-l…
Browse files Browse the repository at this point in the history
…ogic

Invert the logic on whether it's a top-level
  • Loading branch information
erinesullivan authored Dec 10, 2024
2 parents c868586 + a2cf0c3 commit e910358
Showing 1 changed file with 2 additions and 2 deletions.
4 changes: 2 additions & 2 deletions src/modules/browse/organizeByParents.js
Original file line number Diff line number Diff line change
Expand Up @@ -16,8 +16,8 @@ const organizeByParents = (array) => {

return array
.filter((item) => {
return !item.parents.length || item.parents.some((parent) => {
return !parentMap.has(parent);
return !item.parents.length || !item.parents.some((parent) => {
return parentMap.has(parent);
});
})
.map((item) => {
Expand Down

0 comments on commit e910358

Please sign in to comment.