Skip to content

Commit 52554c6

Browse files
author
magiclu550
committed
[JSMOD@2_486_COMMIT] plugins != null
1 parent 7b90c69 commit 52554c6

1 file changed

Lines changed: 6 additions & 4 deletions

File tree

JSMod2Core/src/main/java/cn/jsmod2/core/Server.java

Lines changed: 6 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -511,10 +511,12 @@ private void closeAll(){
511511
log.multiInfo(this.getClass(),lang.getProperty(STOP+".finish"),LogFormat.textFormat("[STOP::"+FileSystem.getFileSystem().serverProperties(server).getProperty("smod2.ip")+"]", Ansi.Color.GREEN).toString(),"");
512512
}
513513
private void disable(){
514-
for(Plugin plugin:plugins){
515-
if(plugin!=null) {
516-
serverLogInfo("unload the plugin named " + plugin.getPluginName());
517-
plugin.onDisable();
514+
if(plugins != null){
515+
for(Plugin plugin:plugins){
516+
if(plugin!=null) {
517+
serverLogInfo("unload the plugin named " + plugin.getPluginName());
518+
plugin.onDisable();
519+
}
518520
}
519521
}
520522
}

0 commit comments

Comments
 (0)