Skip to content

Commit

Permalink
Ignore badges with air material in GUI
Browse files Browse the repository at this point in the history
  • Loading branch information
ZakShearman committed Oct 28, 2023
1 parent eebcd49 commit a6339f0
Showing 1 changed file with 1 addition and 0 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -93,6 +93,7 @@ public BadgeGui(@NotNull BadgeService badgeService, @NotNull Player player) {

private void drawInventory(@NotNull List<Badge> allBadges, @NotNull Set<String> ownedBadgeIds, @Nullable String activeBadgeId) {
List<Badge> badges = allBadges.stream()
.filter(badge -> !badge.getGuiItem().getMaterial().equals("minecraft:air"))
.sorted(Comparator.comparingLong(Badge::getPriority))
.toList();

Expand Down

0 comments on commit a6339f0

Please sign in to comment.