Permalink
Browse files

Add better messages for invalid values

  • Loading branch information...
PseudoKnight committed Aug 11, 2018
1 parent cd75e1a commit d0bd036e74d9ad12fc8f750f516f0e98da61d573
Showing with 4 additions and 1 deletion.
  1. +4 −1 src/main/java/com/laytonsmith/core/ObjectGenerator.java
@@ -319,10 +319,13 @@ public MCItemStack item(Construct i, Target t, boolean legacy) {
} else {
ret = StaticLayer.GetItemStack(mat, qty);
}
} else {
throw new CREFormatException("Could not find item name key in array!", t);
}
if(ret == null) {
throw new CREFormatException("Could not find item name!", t);
throw new CREFormatException("Could not find item material from \"" + mat + "\"", t);
}
if(item.containsKey("meta")) {

0 comments on commit d0bd036

Please sign in to comment.