mirror of
https://github.com/PaperMC/Paper.git
synced 2025-03-22 11:39:49 +01:00
SPIGOT-1325: Make ItemStack deserialization more robust.
By: md_5 <git@md-5.net>
This commit is contained in:
parent
107ff2ff80
commit
bed18dc5ab
@ -530,7 +530,7 @@ public class ItemStack implements Cloneable, ConfigurationSerializable {
|
||||
}
|
||||
|
||||
if (args.containsKey("amount")) {
|
||||
amount = (Integer) args.get("amount");
|
||||
amount = ((Number) args.get("amount")).intValue();
|
||||
}
|
||||
|
||||
ItemStack result = new ItemStack(type, amount, damage);
|
||||
|
Loading…
Reference in New Issue
Block a user