Skip to content
This repository has been archived by the owner on Aug 31, 2019. It is now read-only.

Commit

Permalink
Fix firstEmpty
Browse files Browse the repository at this point in the history
  • Loading branch information
cswhite2000 committed May 3, 2017
1 parent 6111a01 commit dad6b95
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion CraftBukkit/Reduce-ItemStack-copying.patch
Original file line number Diff line number Diff line change
Expand Up @@ -263,7 +263,7 @@ diff --git a/src/main/java/org/bukkit/craftbukkit/inventory/CraftInventory.java
- }
- }
- return -1;
+ return ListUtils.indexOf(storage(), Objects::isNull);
+ return ListUtils.indexOf(storage(), item -> item == null || Material.AIR.equals(item.getType()));
}

public int firstPartial(int materialId) {
Expand Down

0 comments on commit dad6b95

Please sign in to comment.