mirror of
https://github.com/BentoBoxWorld/BentoBox.git
synced 2025-01-09 18:08:27 +01:00
Fix broken test for IslandRespawnListener
This commit is contained in:
parent
ea6ca3d26b
commit
7040047fcb
@ -69,7 +69,7 @@ public class IslandRespawnListener extends FlagListener {
|
||||
if (respawnLocation != null) {
|
||||
e.setRespawnLocation(respawnLocation);
|
||||
// Get the island owner name
|
||||
Island island = BentoBox.getInstance().getIslandsManager().getIsland(w, User.getInstance(e.getPlayer()));
|
||||
Island island = BentoBox.getInstance().getIslands().getIsland(w, User.getInstance(e.getPlayer()));
|
||||
if (island != null) {
|
||||
ownerName = BentoBox.getInstance().getPlayers().getName(island.getOwner());
|
||||
}
|
||||
|
@ -88,6 +88,7 @@ public class IslandRespawnListenerTest {
|
||||
when(player.getUniqueId()).thenReturn(UUID.randomUUID());
|
||||
when(player.getLocation()).thenReturn(mock(Location.class));
|
||||
when(player.getServer()).thenReturn(server);
|
||||
when(player.getName()).thenReturn("tasty");
|
||||
|
||||
// Island World Manager
|
||||
// All locations are in world by default
|
||||
|
Loading…
Reference in New Issue
Block a user