From 8b4f7a74d36fad5d66d7e8160262253746018ea9 Mon Sep 17 00:00:00 2001 From: Yannick Lamprecht <1420893+yannicklamprecht@users.noreply.github.com> Date: Sat, 27 Apr 2019 15:10:19 +0100 Subject: [PATCH] Exceptions are not thrown by API methods. --- .../de/themoep/randomteleport/api/RandomTeleportAPI.java | 6 ++---- 1 file changed, 2 insertions(+), 4 deletions(-) diff --git a/randomteleport-plugin/src/main/java/de/themoep/randomteleport/api/RandomTeleportAPI.java b/randomteleport-plugin/src/main/java/de/themoep/randomteleport/api/RandomTeleportAPI.java index 93a5728..dcd18d3 100644 --- a/randomteleport-plugin/src/main/java/de/themoep/randomteleport/api/RandomTeleportAPI.java +++ b/randomteleport-plugin/src/main/java/de/themoep/randomteleport/api/RandomTeleportAPI.java @@ -49,7 +49,7 @@ public interface RandomTeleportAPI { * @param validators additional LocationValidators to customize validity check of a location * @return a CompletableFuture true if teleport was successful else false */ - CompletableFuture teleportToRandomLocation(Player player, Location center, int minRange, int maxRange, LocationValidator... validators) throws ExecutionException, InterruptedException; + CompletableFuture teleportToRandomLocation(Player player, Location center, int minRange, int maxRange, LocationValidator... validators); /** * Creates a RandomSearcher instance with the passed parameters @@ -60,8 +60,6 @@ public interface RandomTeleportAPI { * @param maxRange the maximum distance a found location has to the center location * @param validators additional LocationValidators to customize validity check of a location * @return a randomSearcher instance - * @throws ExecutionException see {@link CompletableFuture#get()} - * @throws InterruptedException see {@link CompletableFuture#get()} */ - RandomSearcher getRandomSearcher(Player player, Location center, int minRange, int maxRange, LocationValidator... validators) throws ExecutionException, InterruptedException; + RandomSearcher getRandomSearcher(Player player, Location center, int minRange, int maxRange, LocationValidator... validators); }