Skip to content

Commit

Permalink
Make the badge selector also show the default selected badges
Browse files Browse the repository at this point in the history
  • Loading branch information
Nexite committed Feb 28, 2021
1 parent 0578b8c commit d88bff1
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion src/components/UserProperty/Badges.js
Original file line number Diff line number Diff line change
Expand Up @@ -31,7 +31,7 @@ const Badges = ({ user, onChange }) => {
return [...previousBadges.filter((b) => b.displayed == false), ...newDisplayedBadges] || []
}
}, user.badges || []);
const displayedBadges = badges.filter((b) => b.displayed == true).sort((a, b) => a.order - b.order) || []
const displayedBadges = user.displayedBadges || [];
const badgesAlphabetical = [...badges].sort((a, b) => a.id.localeCompare(b.id))

return (
Expand Down

0 comments on commit d88bff1

Please sign in to comment.