Skip to content

Commit a964529

Browse files
committed
refactor(ScanSummary): Inline two variables
Make the code consistent with the function below. Signed-off-by: Frank Viernau <[email protected]>
1 parent 6945f1b commit a964529

File tree

1 file changed

+2
-5
lines changed

1 file changed

+2
-5
lines changed

model/src/main/kotlin/ScanSummary.kt

Lines changed: 2 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -120,12 +120,9 @@ data class ScanSummary(
120120

121121
fun TextLocation.matchesPath() = this.path.startsWith("$path/") || this.path in applicableLicenseFiles
122122

123-
val licenseFindings = licenseFindings.filterTo(mutableSetOf()) { it.location.matchesPath() }
124-
val copyrightFindings = copyrightFindings.filterTo(mutableSetOf()) { it.location.matchesPath() }
125-
126123
return copy(
127-
licenseFindings = licenseFindings,
128-
copyrightFindings = copyrightFindings
124+
licenseFindings = licenseFindings.filterTo(mutableSetOf()) { it.location.matchesPath() },
125+
copyrightFindings = copyrightFindings.filterTo(mutableSetOf()) { it.location.matchesPath() }
129126
)
130127
}
131128

0 commit comments

Comments
 (0)