From 43701c1fe8bf4e0bdbfefb4c6682377e75c8fddc Mon Sep 17 00:00:00 2001 From: libraryaddict Date: Wed, 19 Dec 2018 15:10:15 +1300 Subject: [PATCH] Add messages for errors in LibsPremium and when commands are disabled --- src/main/java/me/libraryaddict/disguise/LibsDisguises.java | 2 ++ .../me/libraryaddict/disguise/utilities/LibsPremium.java | 5 +++++ 2 files changed, 7 insertions(+) diff --git a/src/main/java/me/libraryaddict/disguise/LibsDisguises.java b/src/main/java/me/libraryaddict/disguise/LibsDisguises.java index 5f8da6a2..eb63d1f3 100644 --- a/src/main/java/me/libraryaddict/disguise/LibsDisguises.java +++ b/src/main/java/me/libraryaddict/disguise/LibsDisguises.java @@ -85,6 +85,8 @@ public class LibsDisguises extends JavaPlugin { registerCommand("disguisemodifyplayer", new DisguiseModifyPlayerCommand()); registerCommand("disguisemodifyradius", new DisguiseModifyRadiusCommand(getConfig().getInt("DisguiseRadiusMax"))); + } else { + getLogger().info("Commands has been disabled, as per config"); } infectWithMetrics(); diff --git a/src/main/java/me/libraryaddict/disguise/utilities/LibsPremium.java b/src/main/java/me/libraryaddict/disguise/utilities/LibsPremium.java index 2568ceee..aa7eccbc 100644 --- a/src/main/java/me/libraryaddict/disguise/utilities/LibsPremium.java +++ b/src/main/java/me/libraryaddict/disguise/utilities/LibsPremium.java @@ -57,7 +57,12 @@ public class LibsPremium { ") in the folder!"); } } + catch (ClassNotFoundException ex) { + DisguiseUtilities.getLogger() + .warning("Found an unrecognized jar in the LibsDisguises folder (" + file.getName() + ")"); + } catch (Exception ex) { + DisguiseUtilities.getLogger().warning("Error while trying to handle the file " + file.getName()); ex.printStackTrace(); // Don't print off errors }