Skip to content

Commit

Permalink
exclude 2023 from default view
Browse files Browse the repository at this point in the history
  • Loading branch information
DarkIntaqt committed Jan 10, 2024
1 parent 9a6f1db commit 740a5f0
Show file tree
Hide file tree
Showing 2 changed files with 3 additions and 12 deletions.
5 changes: 1 addition & 4 deletions src/module/Challenges.js
Original file line number Diff line number Diff line change
Expand Up @@ -271,10 +271,7 @@ class Challenges extends Component {
// Skip to next element if filter is on and not on element
if (this.filter.category.length > 0 && !this.filter.category.includes(parentId.toString())) {
if (this.filter.category.includes("seasonal-retired")) {
if (parentId !== 2022000) {
continue;
}
if (parentId !== 2023000) {
if (parentId !== 2022000 && parentId !== 2023000) {
continue;
}
} else {
Expand Down
10 changes: 2 additions & 8 deletions src/module/user/orderChallenges.js
Original file line number Diff line number Diff line change
Expand Up @@ -115,21 +115,15 @@ export function removeUnnecessaryChallenges(challengesArray, filters, masterOnly

if (filters.category.length > 0 && !filters.category.includes(parentId.toString())) {
if (filters.category.includes("retired-seasonal")) {
if (parentId !== 2022000) {
return null
}
if (parentId !== 2023000) {
if (parentId !== 2022000 && parentId !== 2023000) {
return null
}
} else {
return null
}
}
if (filters.category.length === 0) {
if (parentId === 2022000) {
return null
}
if (parentId !== 2023000) {
if (parentId === 2022000 || parentId === 2023000) {
return null
}
}
Expand Down

0 comments on commit 740a5f0

Please sign in to comment.