Skip to content

Commit

Permalink
fix style error
Browse files Browse the repository at this point in the history
  • Loading branch information
mgaido91 committed Jan 21, 2018
1 parent d9d25b0 commit 8c162a3
Showing 1 changed file with 4 additions and 2 deletions.
6 changes: 4 additions & 2 deletions mllib/src/main/scala/org/apache/spark/ml/param/params.scala
Original file line number Diff line number Diff line change
Expand Up @@ -277,15 +277,17 @@ object ParamValidators {

val mustUnsetParams = excludedParams.filter(p => model.isSet(p))
.map(_.name).mkString(", ")
if (mustUnsetParams.nonEmpty)
if (mustUnsetParams.nonEmpty) {
badParamsMsgBuilder ++=
s"The following Params are not applicable and should not be set: $mustUnsetParams."
}

val mustSetParams = requiredParams.filter(p => !model.isDefined(p))
.map(_.name).mkString(", ")
if (mustSetParams.nonEmpty)
if (mustSetParams.nonEmpty) {
badParamsMsgBuilder ++=
s"The following Params must be defined but are not set: $mustSetParams."
}

val badParamsMsg = badParamsMsgBuilder.toString()

Expand Down

0 comments on commit 8c162a3

Please sign in to comment.