Skip to content

Commit 4c88573

Browse files
committed
Make the patch version work for 10 >= 2.
1 parent 8b0f3cc commit 4c88573

File tree

1 file changed

+4
-5
lines changed

1 file changed

+4
-5
lines changed

src/main/scala/scoverage/ScoverageSbtPlugin.scala

+4-5
Original file line numberDiff line numberDiff line change
@@ -89,14 +89,13 @@ object ScoverageSbtPlugin extends AutoPlugin {
8989
}
9090

9191
private def isScala3SupportingFilePackageExclusion(scalaVersion: String) = {
92-
def patch = scalaVersion.split('.').drop(2).headOption
92+
def patch = scalaVersion.split('.').map(_.toInt).drop(2).headOption
9393
CrossVersion
9494
.partialVersion(scalaVersion)
9595
.exists {
96-
case (3, minor)
97-
if minor > 4 || (minor == 4 && patch.exists(_ >= "2")) =>
98-
true
99-
case _ => false
96+
case (3, minor) if minor > 4 => true
97+
case (3, minor) if (minor == 4 && patch.exists(_ >= 2)) => true
98+
case _ => false
10099
}
101100
}
102101

0 commit comments

Comments
 (0)