replace to math min

This commit is contained in:
brenoepic 2022-04-30 02:06:45 -03:00
parent 0a4d934c10
commit cb3486418d

View File

@ -1289,7 +1289,7 @@ public class RoomManager {
Collections.sort(rooms);
return rooms.subList(0, (rooms.size() > limit ? limit : rooms.size()));
return rooms.subList(0, (Math.min(rooms.size(), limit)));
}
public ArrayList<Room> getRoomsWithRights(Habbo habbo) {