Skip to content

Commit

Permalink
Add explicit type in StateChanger's handling
Browse files Browse the repository at this point in the history
  • Loading branch information
alba-s committed Jan 15, 2025
1 parent bd31d84 commit bdce422
Showing 1 changed file with 3 additions and 3 deletions.
6 changes: 3 additions & 3 deletions shared/src/main/scala/pact4s/StateChanger.scala
Original file line number Diff line number Diff line change
Expand Up @@ -89,7 +89,7 @@ private[pact4s] object StateChanger {
}
.getOrElse(Map.empty[String, String])
// Apply state change function
val result =
val result: Map[String, String] =
stateChange
.lift(ProviderState(s, params))
.getOrElse {
Expand All @@ -98,8 +98,8 @@ private[pact4s] object StateChanger {
)
Map.empty
}
val results: Map[String, Value] = result.map { case (k, v) => (k, ujson.Str(v)) }
maybeParams.fold(results)(_.toMap ++ results)
val jsonResult: Map[String, Value] = result.map { case (k, v) => (k, ujson.Str(v)) }
maybeParams.fold(jsonResult)(_.toMap ++ jsonResult)
}
}
stateChangeMaybeApplied match {
Expand Down

0 comments on commit bdce422

Please sign in to comment.