diff --git a/pride/src/main/java/com/prezi/gradle/pride/cli/commands/RemoveCommand.java b/pride/src/main/java/com/prezi/gradle/pride/cli/commands/RemoveCommand.java index d0a4dcb..0e9d453 100644 --- a/pride/src/main/java/com/prezi/gradle/pride/cli/commands/RemoveCommand.java +++ b/pride/src/main/java/com/prezi/gradle/pride/cli/commands/RemoveCommand.java @@ -4,6 +4,7 @@ import com.google.common.base.Predicate; import com.google.common.base.Throwables; import com.google.common.collect.Collections2; +import com.google.common.collect.Lists; import com.prezi.gradle.pride.Module; import com.prezi.gradle.pride.Pride; import com.prezi.gradle.pride.PrideException; @@ -49,7 +50,7 @@ public boolean apply(Module module) { } // Remove modules - for (Module module : modules) { + for (Module module : Lists.newArrayList(modules)) { pride.removeModule(module.getName()); } pride.save();