1
0
mirror of https://github.com/essentials/Essentials.git synced 2025-08-13 10:04:51 +02:00

Formatting.

Signed-off-by: Paul Buonopane <techsoftadvanced@gmail.com>
This commit is contained in:
Paul Buonopane
2012-02-23 12:26:55 -05:00
parent 8c5d4d83f1
commit a865c9ad01

View File

@@ -210,7 +210,8 @@ public class BukkitConstructor extends Constructor
} }
return new EnchantmentLevel(enchant, level); return new EnchantmentLevel(enchant, level);
} }
if (node.getType().isEnum()) { if (node.getType().isEnum())
{
final String val = (String)constructScalar((ScalarNode)node); final String val = (String)constructScalar((ScalarNode)node);
if (val.isEmpty()) if (val.isEmpty())
{ {
@@ -218,7 +219,8 @@ public class BukkitConstructor extends Constructor
} }
for (Object object : node.getType().getEnumConstants()) for (Object object : node.getType().getEnumConstants())
{ {
if (object.toString().equalsIgnoreCase(val)) { if (object.toString().equalsIgnoreCase(val))
{
return object; return object;
} }
} }
@@ -292,7 +294,8 @@ public class BukkitConstructor extends Constructor
final Field typeDefField = Constructor.class.getDeclaredField("typeDefinitions"); final Field typeDefField = Constructor.class.getDeclaredField("typeDefinitions");
typeDefField.setAccessible(true); typeDefField.setAccessible(true);
typeDefinitions = (Map<Class<? extends Object>, TypeDescription>)typeDefField.get((Constructor)BukkitConstructor.this); typeDefinitions = (Map<Class<? extends Object>, TypeDescription>)typeDefField.get((Constructor)BukkitConstructor.this);
if (typeDefinitions == null) { if (typeDefinitions == null)
{
throw new NullPointerException(); throw new NullPointerException();
} }
} }