Skip to content

Commit f92c1fa

Browse files
committed
make runTaskLater async in notify for update on join
1 parent c94e7e0 commit f92c1fa

File tree

1 file changed

+1
-1
lines changed
  • src/main/java/pro/cloudnode/smp/bankaccounts/events

1 file changed

+1
-1
lines changed

src/main/java/pro/cloudnode/smp/bankaccounts/events/Join.java

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -26,7 +26,7 @@ public void onPlayerJoin(final @NotNull PlayerJoinEvent event) {
2626
}
2727
}));
2828
if (player.hasPermission(Permissions.NOTIFY_UPDATE)) {
29-
BankAccounts.getInstance().getServer().getScheduler().runTaskLater(BankAccounts.getInstance(), () -> BankAccounts.checkForUpdates().ifPresent(latestVersion -> {
29+
BankAccounts.getInstance().getServer().getScheduler().runTaskLaterAsynchronously(BankAccounts.getInstance(), () -> BankAccounts.checkForUpdates().ifPresent(latestVersion -> {
3030
player.sendMessage(BankAccounts.getInstance().config().messagesUpdateAvailable(latestVersion));
3131
}), 20L);
3232
}

0 commit comments

Comments
 (0)