mirror of
https://github.com/filoghost/ChestCommands.git
synced 2024-11-22 10:05:17 +01:00
Forcefully fail on plugin load if external reload is detected
This commit is contained in:
parent
b90fa741c5
commit
ab8bfc0a8b
@ -69,8 +69,9 @@ public class ChestCommands extends BaseJavaPlugin {
|
||||
}
|
||||
|
||||
if (pluginInstance != null || System.getProperty("ChestCommandsLoaded") != null) {
|
||||
Log.warning("Please do not use /reload or plugin reloaders. Use the command \"/cc reload\" instead.");
|
||||
return;
|
||||
throw new PluginEnableException("External plugin reloading is not supported:"
|
||||
+ " avoid using /reload or plugin reloaders, and use the command \"/cc reload\" instead."
|
||||
+ " Fully restart the server to enable ChestCommands again.");
|
||||
}
|
||||
|
||||
System.setProperty("ChestCommandsLoaded", "true");
|
||||
|
Loading…
Reference in New Issue
Block a user