fix catch

This commit is contained in:
MidnightTale 2023-04-13 13:14:59 +07:00
commit fe569a25ad

View file

@ -53,7 +53,7 @@ public class FoliaFlow extends JavaPlugin implements Listener {
block.setBlockData(slab); block.setBlockData(slab);
} }
}, 1L, 1L); }, 1L, 1L);
} catch (NullPointerException RegionScheduler) { } catch (NullPointerException block) {
getServer().getLogger().info("Region Scheduler erorr (likly chunky it not load)"); getServer().getLogger().info("Region Scheduler erorr (likly chunky it not load)");
} }
try { try {
@ -78,7 +78,7 @@ public class FoliaFlow extends JavaPlugin implements Listener {
} }
} }
}), 0L, 1L, TimeUnit.MILLISECONDS); }), 0L, 1L, TimeUnit.MILLISECONDS);
} catch (NullPointerException AsyncScheduler) { } catch (NullPointerException e) {
getServer().getLogger().info("AsyncScheduler erorr (likly chunky it not load)"); getServer().getLogger().info("AsyncScheduler erorr (likly chunky it not load)");
} }
getServer().getPluginManager().registerEvents(this, this); getServer().getPluginManager().registerEvents(this, this);
@ -95,8 +95,8 @@ public class FoliaFlow extends JavaPlugin implements Listener {
@Override @Override
public void onDisable() { public void onDisable() {
task.isCancelled(); task.cancel();
blockktask.isCancelled(); blockktask.cancel();
super.onDisable(); super.onDisable();
debug(); debug();
} }
@ -128,7 +128,7 @@ public class FoliaFlow extends JavaPlugin implements Listener {
dummy.setVelocity(dummyVel); dummy.setVelocity(dummyVel);
} }
} catch (NullPointerException onFallingBlockToBlock) { } catch (NullPointerException dummy) {
getServer().getLogger().info("onFallingBlockToBlock erorr (likly chunky it not load)"); getServer().getLogger().info("onFallingBlockToBlock erorr (likly chunky it not load)");
} }
} }