Skip to content

Commit

Permalink
🔨 fix filter query
Browse files Browse the repository at this point in the history
  • Loading branch information
danyx23 committed Nov 2, 2023
1 parent 644c39c commit 6eb2fba
Showing 1 changed file with 7 additions and 3 deletions.
10 changes: 7 additions & 3 deletions site/DataPageV2Content.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -154,9 +154,13 @@ export const DataPageV2Content = ({
const relatedResearch =
relatedResearchCandidates.length > 10 &&
datapageData.topicTagsLinks?.length
? relatedResearchCandidates.filter((research) =>
intersection([research.tags, datapageData.topicTagsLinks])
)
? relatedResearchCandidates.filter((research) => {
const shared = intersection(
research.tags,
datapageData.topicTagsLinks ?? []
)
return shared.length > 0
})
: relatedResearchCandidates
// TODO: mark topic pages

Expand Down

0 comments on commit 6eb2fba

Please sign in to comment.