Fixes #860
This commit is contained in:
parent
7a9ed0f512
commit
199eea5d9f
@ -78,4 +78,9 @@ public class BukkitMain extends JavaPlugin {
|
||||
Bukkit.getPluginManager().enablePlugin(toLoad);
|
||||
}
|
||||
}
|
||||
|
||||
@Override
|
||||
public void onDisable() {
|
||||
Fawe.get().onDisable();
|
||||
}
|
||||
}
|
@ -150,6 +150,8 @@ public class Fawe {
|
||||
private DefaultTransformParser transformParser;
|
||||
private ChatManager chatManager = new PlainChatManager();
|
||||
|
||||
private BStats stats;
|
||||
|
||||
/**
|
||||
* Get the implementation specific class
|
||||
*
|
||||
@ -222,7 +224,7 @@ public class Fawe {
|
||||
TaskManager.IMP = this.IMP.getTaskManager();
|
||||
if (Settings.IMP.METRICS) {
|
||||
try {
|
||||
BStats stats = new BStats();
|
||||
this.stats = new BStats();
|
||||
this.IMP.startMetrics();
|
||||
TaskManager.IMP.later(new Runnable() {
|
||||
@Override
|
||||
@ -277,6 +279,12 @@ public class Fawe {
|
||||
}
|
||||
}
|
||||
|
||||
public void onDisable() {
|
||||
if (stats != null) {
|
||||
stats.close();
|
||||
}
|
||||
}
|
||||
|
||||
private boolean update() {
|
||||
if (updater != null) {
|
||||
updater.getUpdate(IMP.getPlatform(), getVersion());
|
||||
|
Loading…
Reference in New Issue
Block a user