Skip to content

Commit

Permalink
fixup
Browse files Browse the repository at this point in the history
  • Loading branch information
zhztheplayer committed Dec 9, 2024
1 parent 3b3c8b4 commit 03c9fc3
Showing 1 changed file with 2 additions and 2 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -231,7 +231,7 @@ object Validators {
import FallbackByNativeValidation._
private val offloadAttempt: LegacyOffload = LegacyOffload(offloadRules)
override def validate(plan: SparkPlan): Validator.OutCome = {
applyAsSingleNode(plan) {
applyOnSingleNode(plan) {
node =>
val offloadedNode = offloadAttempt.apply(node)
val outcomes = offloadedNode.collect {
Expand Down Expand Up @@ -265,7 +265,7 @@ object Validators {
override def outputPartitioning: Partitioning = originalChild.outputPartitioning
}

private def applyAsSingleNode[T](plan: SparkPlan)(body: SparkPlan => T): T = {
private def applyOnSingleNode[T](plan: SparkPlan)(body: SparkPlan => T): T = {
val newChildren = plan.children.map(child => FakeLeaf(originalChild = child))
val newPlan = plan.withNewChildren(newChildren)
val applied = body(newPlan)
Expand Down

0 comments on commit 03c9fc3

Please sign in to comment.