summaryrefslogtreecommitdiffstats
path: root/EssentialsProtect/src/com/earth2me/essentials/protect/EssentialsConnect.java
diff options
context:
space:
mode:
Diffstat (limited to 'EssentialsProtect/src/com/earth2me/essentials/protect/EssentialsConnect.java')
-rw-r--r--EssentialsProtect/src/com/earth2me/essentials/protect/EssentialsConnect.java16
1 files changed, 10 insertions, 6 deletions
diff --git a/EssentialsProtect/src/com/earth2me/essentials/protect/EssentialsConnect.java b/EssentialsProtect/src/com/earth2me/essentials/protect/EssentialsConnect.java
index 9f1cc122a..539ff208b 100644
--- a/EssentialsProtect/src/com/earth2me/essentials/protect/EssentialsConnect.java
+++ b/EssentialsProtect/src/com/earth2me/essentials/protect/EssentialsConnect.java
@@ -66,6 +66,10 @@ public class EssentialsConnect
@Override
public void onReload()
{
+ if (protect.getStorage() != null)
+ {
+ protect.getStorage().onPluginDeactivation();
+ }
/*
* for (ProtectConfig protectConfig : ProtectConfig.values()) { if (protectConfig.isList()) {
@@ -93,7 +97,7 @@ public class EssentialsConnect
settings.getData().getDbuser(),
settings.getData().getDbpassword()));
}
- catch (ClassNotFoundException ex)
+ catch (PropertyVetoException ex)
{
LOGGER.log(Level.SEVERE, null, ex);
}
@@ -104,15 +108,15 @@ public class EssentialsConnect
{
protect.setStorage(new ProtectedBlockSQLite("jdbc:sqlite:plugins/Essentials/EssentialsProtect.db"));
}
- catch (ClassNotFoundException ex)
+ catch (PropertyVetoException ex)
{
LOGGER.log(Level.SEVERE, null, ex);
}
}
- /*
- * if (protect.getSettingBool(ProtectConfig.memstore)) { protect.setStorage(new
- * ProtectedBlockMemory(protect.getStorage(), protect)); }
- */
+ /*if (protect.getSettingBool(ProtectConfig.memstore))
+ {
+ protect.setStorage(new ProtectedBlockMemory(protect.getStorage(), protect));
+ }*/
}
finally