From 28cbac66104f5053cae6166d1895b6fdb6463330 Mon Sep 17 00:00:00 2001 From: Iaccidentally Date: Sun, 28 Apr 2013 17:22:11 -0400 Subject: [PATCH] cleanup last commit a bit --- .../src/com/earth2me/essentials/Warps.java | 19 ++----------------- 1 file changed, 2 insertions(+), 17 deletions(-) diff --git a/Essentials/src/com/earth2me/essentials/Warps.java b/Essentials/src/com/earth2me/essentials/Warps.java index ce1eff83a..39f31369c 100644 --- a/Essentials/src/com/earth2me/essentials/Warps.java +++ b/Essentials/src/com/earth2me/essentials/Warps.java @@ -135,29 +135,14 @@ public class Warps implements IConf, IWarps @Override public Collection getList() { - final List keys = new ArrayList(); - for (StringIgnoreCase stringIgnoreCase : warpPoints.keySet()) - { - keys.add(stringIgnoreCase.getString()); - } - Collections.sort(keys, String.CASE_INSENSITIVE_ORDER); - return keys; + return getWarpNames(); } // This is for api support, and so 3.x will not break this api @Override public void removeWarp(String name) throws Exception { - EssentialsConf conf = warpPoints.get(new StringIgnoreCase(name)); - if (conf == null) - { - throw new Exception(_("warpNotExist")); - } - if (!conf.getFile().delete()) - { - throw new Exception(_("warpDeleteError")); - } - warpPoints.remove(new StringIgnoreCase(name)); + delWarp(name); } //This is here for future 3.x api support. Not implemented here becasue storage is handled differently