Skip to content

Commit 07409c8

Browse files
authored
Merge pull request #627 from Multiverse/fix/deprecated-methods
Fix/deprecated methods
2 parents 2506dec + c7fadd4 commit 07409c8

File tree

3 files changed

+4
-2
lines changed

3 files changed

+4
-2
lines changed

src/main/java/org/mvplugins/multiverse/inventories/destination/LastLocationDestination.java

Lines changed: 2 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -41,7 +41,8 @@ public final class LastLocationDestination implements Destination<LastLocationDe
4141
}
4242

4343
@Override
44-
public @NotNull Attempt<LastLocationDestinationInstance, LastLocationDestination.InstanceFailureReason> getDestinationInstance(@NotNull String destinationParams) {
44+
public @NotNull Attempt<LastLocationDestinationInstance, LastLocationDestination.InstanceFailureReason> getDestinationInstance(
45+
@NotNull CommandSender sender, @NotNull String destinationParams) {
4546
if (!worldManager.isLoadedWorld(destinationParams)) {
4647
return Attempt.failure(InstanceFailureReason.WORLD_NOT_FOUND);
4748
}

src/main/java/org/mvplugins/multiverse/inventories/listeners/SpawnChangeListener.java

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -54,6 +54,7 @@ public void onEvent(PlayerSetSpawnEvent event) {
5454
};
5555
}
5656

57+
@SuppressWarnings("removal")
5758
@EventClass("org.bukkit.event.player.PlayerSpawnChangeEvent")
5859
@SkipIfEventExist("com.destroystokyo.paper.event.player.PlayerSetSpawnEvent")
5960
@DefaultEventPriority(EventPriority.MONITOR)

src/main/java/org/mvplugins/multiverse/inventories/share/Sharables.java

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -652,7 +652,7 @@ public boolean updatePlayer(Player player, ProfileData profile) {
652652
if (loc == null || loc.getWorld() == null || loc.equals(player.getLocation())) {
653653
return false;
654654
}
655-
safetyTeleporter.to(loc).checkSafety(false).teleport(player);
655+
safetyTeleporter.to(loc).checkSafety(false).teleportSingle(player);
656656
return true;
657657
}
658658
}).serializer(new ProfileEntry(false, DataStrings.PLAYER_LAST_LOCATION), new LocationSerializer())

0 commit comments

Comments
 (0)