Revert "wtf"

This reverts commit 50219cc4a9.
This commit is contained in:
HaHaWTH
2024-03-28 05:39:26 +08:00
parent 409eb21b85
commit 44e4790e45
7 changed files with 16 additions and 12 deletions
@@ -1,5 +1,6 @@
package fr.xephi.authme.initialization;
import com.github.Anon8281.universalScheduler.UniversalRunnable;
import fr.xephi.authme.AuthMe;
import fr.xephi.authme.ConsoleLogger;
import fr.xephi.authme.datasource.DataSource;
@@ -18,7 +19,6 @@ import org.bstats.bukkit.Metrics;
import org.bstats.charts.SimplePie;
import org.bukkit.Bukkit;
import org.bukkit.entity.Player;
import org.bukkit.scheduler.BukkitRunnable;
import javax.inject.Inject;
import java.util.List;
@@ -96,7 +96,7 @@ public class OnStartupTasks {
if (!settings.getProperty(RECALL_PLAYERS)) {
return;
}
bukkitService.runTaskTimerAsynchronously(new BukkitRunnable() {
bukkitService.runTaskTimerAsynchronously(new UniversalRunnable() {
@Override
public void run() {
List<String> loggedPlayersWithEmptyMail = dataSource.getLoggedPlayersWithEmptyMail();
@@ -25,6 +25,7 @@ public class TaskCloser implements Runnable {
@Override
public void run() {
scheduler.cancelTasks();
if (dataSource != null) {
dataSource.closeConnection();
}