diff --git a/src/de/craftinc/gates/dynmap/Plugin.java b/src/de/craftinc/gates/dynmap/Plugin.java index f9a8fae..1a1c91e 100644 --- a/src/de/craftinc/gates/dynmap/Plugin.java +++ b/src/de/craftinc/gates/dynmap/Plugin.java @@ -116,7 +116,12 @@ public class Plugin extends JavaPlugin implements GateChangeListener @Override public void gateChangedHandler(final Gate gate, final Map stringObjectMap) { - String oldID = (String)stringObjectMap.get(GateChangeListener.changedID); - this.markerUtil.updateMarker(gate, oldID); + if (stringObjectMap.containsKey(GateChangeListener.removedGate)) { + this.markerUtil.removeMarker(gate); + } + else { + String oldID = (String)stringObjectMap.get(GateChangeListener.changedID); + this.markerUtil.updateMarker(gate, oldID); + } } }