Add message when QS cannot load Economy and Vault.

This commit is contained in:
Ghost_chu committed 2018-07-28 15:12:17 +08:00
1 parent b04bf87e73
commit 2f6bff9f84
1 file changed
+8 -1
@@ -469,10 +469,11 @@ public class QuickShop extends JavaPlugin {
* and vault cannot be used.
*/
public boolean loadEcon() {
try {
EconomyCore core = new Economy_Vault();
if (core == null || !core.isValid()) {
// getLogger().severe("Economy is not valid!");
getLogger().severe("QuickShop could not hook an economy!");
getLogger().severe("QuickShop could not hook an economy/Not found Vault!");
getLogger().severe("QuickShop CANNOT start!");
this.getPluginLoader().disablePlugin(this);
// if(econ.equals("Vault"))
@@ -482,6 +483,12 @@ public class QuickShop extends JavaPlugin {
this.economy = new Economy(core);
return true;
}
}catch (Exception e) {
e.printStackTrace();
getLogger().severe("QuickShop could not hook an economy/Not found Vault!");
getLogger().severe("QuickShop CANNOT start!");
return false;
}
}
public void onDisable() {