Added log statements when gates get closed during serialization.

This commit is contained in:
Tobias Ottenweller 2013-02-15 23:36:14 +01:00
parent cd0ebc3a7a
commit 56a5f828ee

View File

@ -120,12 +120,13 @@ public class Gate extends BaseGate implements ConfigurationSerializable
validate(); // make sure to not write invalid stuff to disk validate(); // make sure to not write invalid stuff to disk
} }
catch (Exception e) { catch (Exception e) {
Plugin.log("Gate " + this.getId() + " seems to be not valid. It got closed before serializing!");
} }
Map<String, Object> retVal = new HashMap<String, Object>(); Map<String, Object> retVal = new HashMap<String, Object>();
retVal.put(idKey, id); retVal.put(idKey, id);
retVal.put(locationKey, LocationSerializer.serializeLocation(location)); retVal.put(locationKey, LocationSerializer.serializeLocation(location));
retVal.put(exitKey, LocationSerializer.serializeLocation(exit)); retVal.put(exitKey, LocationSerializer.serializeLocation(exit));
retVal.put(isHiddenKey, isHidden); retVal.put(isHiddenKey, isHidden);
retVal.put(isOpenKey, isOpen); retVal.put(isOpenKey, isOpen);