Added context to raw stack trace dump after exception.

This commit is contained in:
tastybento 2018-02-06 15:55:31 -08:00
parent 672d43fb67
commit 1e920825ef
2 changed files with 3 additions and 3 deletions

View File

@ -57,14 +57,14 @@ public class BSkyBlock extends JavaPlugin {
//settings.saveSettings();
settings = settings.loadSettings();
} catch (Exception e) {
e.printStackTrace();
getLogger().severe("Settings could not be loaded" + e.getMessage());
}
// Save a backup of settings to the database so it can be checked next time
try {
settings.saveBackup();
} catch (Exception e) {
e.printStackTrace();
getLogger().severe("Settings backup could not be saved" + e.getMessage());
}
playersManager = new PlayersManager(this);

View File

@ -39,7 +39,7 @@ public interface ISettings<T> {
// --------------- Loader ------------------
@SuppressWarnings("unchecked")
default T loadSettings() throws InstantiationException, IllegalAccessException, IllegalArgumentException, InvocationTargetException, SecurityException, ClassNotFoundException, IntrospectionException, SQLException {
default T loadSettings() throws Exception {
// See if this settings object already exists in the database
AbstractDatabaseHandler<T> dbhandler = (AbstractDatabaseHandler<T>) BSBDatabase.getDatabase().getHandler(this.getClass());
T dbConfig = null;