Try to fix a problem with attribute ?

This commit is contained in:
Xephi59 2015-01-08 20:07:05 +01:00
parent 1a499150c8
commit d0234c182c

View File

@ -107,8 +107,11 @@ public class FileCache {
Attribute a = attributes.values().iterator().next();
if (a != null) {
try {
writer.write("attribute=" + a.getName() + ";" + a.getAttributeType().getMinecraftId() + ";" + a.getAmount() + ";" + a.getOperation().getId() + ";" + a.getUUID().toString());
} catch (Exception e) {}
if (a.getName() != null && a.getAttributeType() != null
&& a.getOperation() != null && a.getUUID() != null)
writer.write("attribute=" + a.getName() + ";" + a.getAttributeType().getMinecraftId() + ";" + a.getAmount() + ";" + a.getOperation().getId() + ";" + a.getUUID().toString());
} catch (Exception e) {
} catch (Error e) {}
}
}
} else {
@ -158,7 +161,9 @@ public class FileCache {
Attribute a = attributes.values().iterator().next();
if (a != null) {
try {
writer.write("attribute=" + a.getName() + ";" + a.getAttributeType().getMinecraftId() + ";" + a.getAmount() + ";" + a.getOperation().getId() + ";" + a.getUUID().toString());
if (a.getName() != null && a.getAttributeType() != null
&& a.getOperation() != null && a.getUUID() != null)
writer.write("attribute=" + a.getName() + ";" + a.getAttributeType().getMinecraftId() + ";" + a.getAmount() + ";" + a.getOperation().getId() + ";" + a.getUUID().toString());
} catch (Exception e) {}
}
}