mirror of
https://github.com/darksaid98/HuskHomes.git
synced 2026-12-02 22:17:17 +00:00
Add handling for TeleportExceptions thrown when completing TimedTeleports
This commit is contained in:
5 files changed
+31
-20
No files matched your search
@@ -23,6 +23,7 @@ import com.zaxxer.hikari.HikariDataSource;
|
||||
import net.william278.huskhomes.HuskHomes;
|
||||
import net.william278.huskhomes.position.*;
|
||||
import net.william278.huskhomes.teleport.Teleport;
|
||||
import net.william278.huskhomes.teleport.TeleportationException;
|
||||
import net.william278.huskhomes.user.OnlineUser;
|
||||
import net.william278.huskhomes.user.SavedUser;
|
||||
import net.william278.huskhomes.user.User;
|
||||
@@ -592,6 +593,8 @@ public class MySqlDatabase extends Database {
|
||||
}
|
||||
} catch (SQLException e) {
|
||||
plugin.log(Level.SEVERE, "Failed to query the current teleport of " + onlineUser.getUsername(), e);
|
||||
} catch (TeleportationException e) {
|
||||
e.displayMessage(onlineUser, plugin);
|
||||
}
|
||||
return Optional.empty();
|
||||
}
|
||||
|
||||
Reference in new issue
Block a user