mirror of
https://github.com/ChestShop-authors/ChestShop-3.git
synced 2024-11-15 06:45:11 +01:00
Fix merging of items that aren't actually equal. (Like skulls with textures)
This commit is contained in:
parent
765548e0e5
commit
11d2280d3e
@ -48,7 +48,10 @@ public class MaterialUtil {
|
|||||||
* @return Are they equal?
|
* @return Are they equal?
|
||||||
*/
|
*/
|
||||||
public static boolean equals(ItemStack one, ItemStack two) {
|
public static boolean equals(ItemStack one, ItemStack two) {
|
||||||
return one.isSimilar(two);
|
return one.isSimilar(two)
|
||||||
|
&& one.toString().equals(two.toString());
|
||||||
|
// The string comparision is necessary as CB has a bug where it counts items with similar ItemMeta
|
||||||
|
// but different NBT data as being equal. (See https://hub.spigotmc.org/jira/browse/SPIGOT-3077)
|
||||||
}
|
}
|
||||||
|
|
||||||
/**
|
/**
|
||||||
|
Loading…
Reference in New Issue
Block a user