Generics.

This commit is contained in:
Business Goose 2022-03-29 23:03:43 +01:00
parent 0b293b7a0d
commit 454a342a9a
No known key found for this signature in database
GPG key ID: 77DCA801362E9645

View file

@ -8,6 +8,7 @@ import org.bukkit.command.CommandSender;
import org.bukkit.entity.Player;
import java.util.ArrayList;
import java.util.List;
@CommandPermissions(level = AdminLevel.SUPER, source = SourceType.BOTH)
public class Command_findip extends FreedomCommand {
@ -28,10 +29,10 @@ public class Command_findip extends FreedomCommand {
PlayerRank rank = PlayerRank.fromSender(sender);
PlayerRank targetRank = PlayerRank.fromSender(player);
ArrayList<String> ipsToShow = (ArrayList<String>) PlayerList.getEntry(player).getIps();
List<String> ipsToShow = PlayerList.getEntry(player).getIps();
if(rank.getOrdinal() < PlayerRank.SENIOR.getOrdinal() || targetRank.getOrdinal() >= rank.getOrdinal()) {
ipsToShow = (ArrayList<String>) PlayerList.getEntry(player).getFuzziedIps();
ipsToShow = PlayerList.getEntry(player).getFuzziedIps();
}