summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
-rw-r--r--Essentials/src/com/earth2me/essentials/signs/SignTrade.java3
1 files changed, 2 insertions, 1 deletions
diff --git a/Essentials/src/com/earth2me/essentials/signs/SignTrade.java b/Essentials/src/com/earth2me/essentials/signs/SignTrade.java
index 37501f1aa..4029be5b7 100644
--- a/Essentials/src/com/earth2me/essentials/signs/SignTrade.java
+++ b/Essentials/src/com/earth2me/essentials/signs/SignTrade.java
@@ -32,7 +32,8 @@ public class SignTrade extends EssentialsSign
validateTrade(sign, 2, true, ess);
final Trade trade = getTrade(sign, 2, AmountType.ROUNDED, true, ess);
final Trade charge = getTrade(sign, 1, AmountType.ROUNDED, false, ess);
- if (trade.getType() == charge.getType() && (trade.getType() != TradeType.ITEM || trade.getItemStack().getType().equals(charge.getItemStack().getType())))
+ if (trade.getType() == charge.getType()
+ && (trade.getType() != TradeType.ITEM || trade.getItemStack().isSimilar(charge.getItemStack())))
{
throw new SignException("You cannot trade for the same item type.");
}