修复空指针报错...

Signed-off-by: 502647092 <jtb1@163.com>
dev
502647092 2015-11-29 18:00:19 +08:00
parent 56058007b5
commit 599c3e9a30
1 changed files with 1 additions and 1 deletions

View File

@ -587,7 +587,7 @@ public class PluginsManager {
}
result = true;
sender.sendMessage("§6升级: §a开始升级 " + name + " 插件!");
if (!unload(plugin)) {
if (plugin != null && !unload(plugin)) {
FileUtil.copy(file, new File(Bukkit.getUpdateFolderFile().getParentFile(), File.separatorChar + file.getName()));
}
load(name);