diff options
Diffstat (limited to 'project')
-rw-r--r-- | project/SparkBuild.scala | 7 |
1 files changed, 4 insertions, 3 deletions
diff --git a/project/SparkBuild.scala b/project/SparkBuild.scala index 83a7c0864f..d164ead4ba 100644 --- a/project/SparkBuild.scala +++ b/project/SparkBuild.scala @@ -212,9 +212,10 @@ object SparkBuild extends PomBuild { cachedFun(findFiles(scalaSource.in(config).value)) } - private def findFiles(file: File): Set[File] = file.isDirectory match { - case true => file.listFiles().toSet.flatMap(findFiles) + file - case false => Set(file) + private def findFiles(file: File): Set[File] = if (file.isDirectory) { + file.listFiles().toSet.flatMap(findFiles) + file + } else { + Set(file) } def enableScalaStyle: Seq[sbt.Def.Setting[_]] = Seq( |