Skip to content

Commit 666d7b7

Browse files
committed
fix(jacoco): Use safe reference navigator operator
Fixes #518
1 parent 05424a1 commit 666d7b7

File tree

1 file changed

+2
-2
lines changed
  • plugins/jacoco-gradle-plugin/src/main/groovy/org/kordamp/gradle/plugin/jacoco

1 file changed

+2
-2
lines changed

plugins/jacoco-gradle-plugin/src/main/groovy/org/kordamp/gradle/plugin/jacoco/JacocoPlugin.groovy

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -258,10 +258,10 @@ class JacocoPlugin extends AbstractKordampPlugin {
258258
Set<Project> projects = [project] as Set
259259

260260
if (config.coverage.jacoco.includeProjectDependencies) {
261-
project.configurations.findByName(testTask.name + 'Implementation').allDependencies.each { d ->
261+
project.configurations.findByName(testTask.name + 'Implementation')?.allDependencies?.each { d ->
262262
if (d instanceof ProjectDependency) projects << d.dependencyProject
263263
}
264-
project.configurations.findByName(testTask.name + 'RuntimeOnly').allDependencies.each { d ->
264+
project.configurations.findByName(testTask.name + 'RuntimeOnly')?.allDependencies?.each { d ->
265265
if (d instanceof ProjectDependency) projects << d.dependencyProject
266266
}
267267
}

0 commit comments

Comments
 (0)