diff --git a/core/src/main/scala/org/apache/spark/Partitioner.scala b/core/src/main/scala/org/apache/spark/Partitioner.scala index c852723bd4b49..1d882764c40cc 100644 --- a/core/src/main/scala/org/apache/spark/Partitioner.scala +++ b/core/src/main/scala/org/apache/spark/Partitioner.scala @@ -60,7 +60,8 @@ object Partitioner { def defaultPartitioner(rdd: RDD[_], others: RDD[_]*): Partitioner = { val rdds = (Seq(rdd) ++ others) val hasPartitioner = rdds.filter(_.partitioner.exists(_.numPartitions > 0)) - if (hasPartitioner.nonEmpty && isEligiblePartitioner(hasPartitioner.maxBy(_.partitions.length), rdds)) { + if (hasPartitioner.nonEmpty + && isEligiblePartitioner(hasPartitioner.maxBy(_.partitions.length), rdds)) { hasPartitioner.maxBy(_.partitions.length).partitioner.get } else { if (rdd.context.conf.contains("spark.default.parallelism")) {