From 51a4c2f4b23eb5869e792907e1fc39286551b9d9 Mon Sep 17 00:00:00 2001 From: Bukkit/Spigot Date: Wed, 15 Jan 2020 21:47:56 +1100 Subject: [PATCH] Revert "SPIGOT-5515: Add basic validation against creating non-item itemstacks" This reverts commit e5ce128c4563ea50967f38b3a32797ad9e70bebc. By: md_5 --- paper-api/src/main/java/org/bukkit/inventory/ItemStack.java | 2 -- 1 file changed, 2 deletions(-) diff --git a/paper-api/src/main/java/org/bukkit/inventory/ItemStack.java b/paper-api/src/main/java/org/bukkit/inventory/ItemStack.java index a37ac7caeb..bab86d8049 100644 --- a/paper-api/src/main/java/org/bukkit/inventory/ItemStack.java +++ b/paper-api/src/main/java/org/bukkit/inventory/ItemStack.java @@ -68,7 +68,6 @@ public class ItemStack implements Cloneable, ConfigurationSerializable { @Deprecated public ItemStack(@NotNull final Material type, final int amount, final short damage, @Nullable final Byte data) { Validate.notNull(type, "Material cannot be null"); - Validate.isTrue(type.isItem(), "Material must be an item: ", type); this.type = type; this.amount = amount; if (damage != 0) { @@ -117,7 +116,6 @@ public class ItemStack implements Cloneable, ConfigurationSerializable { @Utility public void setType(@NotNull Material type) { Validate.notNull(type, "Material cannot be null"); - Validate.isTrue(type.isItem(), "Material must be an item: ", type); this.type = type; if (this.meta != null) { this.meta = Bukkit.getItemFactory().asMetaFor(meta, type);