Guava migration - Inline Iterables.removeAll (Collection overload)

This commit is contained in:
Jetz
2024-09-06 19:58:24 -04:00
parent efe55efa43
commit c1de0dee6a
2 changed files with 1 additions and 5 deletions

View File

@@ -83,10 +83,6 @@ public class Iterables {
return iterable.removeIf(test);
}
public static boolean removeAll(Collection<?> removeFrom, Collection<?> toRemove) {
return removeFrom.removeAll(toRemove);
}
public static int size(Collection<?> collection) {
return collection.size();
}

View File

@@ -1255,7 +1255,7 @@ public class PlayerControllerHuman extends PlayerController implements IGameCont
final List<String> invalidTypes, final boolean isOptional) {
final List<String> types = Lists.newArrayList(validTypes);
if (invalidTypes != null && !invalidTypes.isEmpty()) {
Iterables.removeAll(types, invalidTypes);
types.removeAll(invalidTypes);
}
if (kindOfType.equals("Creature")) {
sortCreatureTypes(types);