@@ -142,18 +142,25 @@ private[librarymanagement] abstract class UpdateReportExtra {
142142 }
143143 }
144144
145- def allModuleReports : Vector [ModuleReport ] = {
146- configurations.flatMap(_.modules).groupBy(mR => moduleKey(mR.module)).toVector map {
147- case (_, v) =>
148- v reduceLeft { (agg, x) =>
149- agg.withConfigurations(
150- (agg.configurations, x.configurations) match {
151- case (v, _) if v.isEmpty => x.configurations
152- case (ac, v) if v.isEmpty => ac
153- case (ac, xc) => ac ++ xc
154- }
155- )
156- }
145+ def allModuleReports : Vector [ModuleReport ] = allModuleReports(_ => true )
146+
147+ def allModuleReports (
148+ filterConfiguration : ConfigurationReport => Boolean
149+ ): Vector [ModuleReport ] = {
150+ configurations
151+ .filter(filterConfiguration)
152+ .flatMap(_.modules)
153+ .groupBy(mR => moduleKey(mR.module))
154+ .toVector map { case (_, v) =>
155+ v reduceLeft { (agg, x) =>
156+ agg.withConfigurations(
157+ (agg.configurations, x.configurations) match {
158+ case (v, _) if v.isEmpty => x.configurations
159+ case (ac, v) if v.isEmpty => ac
160+ case (ac, xc) => ac ++ xc
161+ }
162+ )
163+ }
157164 }
158165 }
159166
0 commit comments