Skip to content

Commit

Permalink
Merge pull request #50 from MilyMilo/fix-empty-category
Browse files Browse the repository at this point in the history
Fix challenge board so with challenges with an empty category aren't loaded multiple times
  • Loading branch information
ColdHeat authored Jul 4, 2023
2 parents c7b4b78 + f2885d9 commit 6b6fbcb
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion assets/js/challenges.js
Original file line number Diff line number Diff line change
Expand Up @@ -202,7 +202,7 @@ Alpine.data("ChallengeBoard", () => ({
getChallenges(category) {
let challenges = this.challenges;

if (category) {
if (category !== null) {
challenges = this.challenges.filter(challenge => challenge.category === category);
}

Expand Down

0 comments on commit 6b6fbcb

Please sign in to comment.