Change how authme reload works, but don't forget ...

This commit is contained in:
Xephi59
2015-07-06 18:02:44 +02:00
parent e021a32f1f
commit 6aad66b731
2 changed files with 37 additions and 38 deletions
@@ -125,7 +125,6 @@ public class AdminCommand implements CommandExecutor {
return true;
}
} else if (args[0].equalsIgnoreCase("reload")) {
database.reload();
File newConfigFile = new File("plugins" + File.separator + "AuthMe", "config.yml");
if (!newConfigFile.exists()) {
InputStream fis = getClass().getResourceAsStream("" + File.separator + "config.yml");
@@ -156,6 +155,8 @@ public class AdminCommand implements CommandExecutor {
Settings.reloadConfigOptions(newConfig);
m.reLoad();
s.reLoad();
plugin.database.close();
plugin.setupDatabase();
m.send(sender, "reload");
} else if (args[0].equalsIgnoreCase("lastlogin")) {
if (args.length != 2) {