Skip to content

Instantly share code, notes, and snippets.

@gbougeard
Last active August 29, 2015 13:57
Show Gist options
  • Select an option

  • Save gbougeard/9894060 to your computer and use it in GitHub Desktop.

Select an option

Save gbougeard/9894060 to your computer and use it in GitHub Desktop.
[JsResultException: JsResultException(errors:List((/fields/customfield_10233/value,List(ValidationError(error.path.missing,WrappedArray())))))]
(__ \ "fields" \ "customfield_10233" \ "value").readNullable[String]
(__ \ "fields" \ "customfield_10233").readNullable(
(__ \ "value").readNullable[String]) ~
//GOTCHA!!
(__ \ "fields" \ "customfield_10233").readNullable(
(__ \ "value").read[String])
@gbougeard

Copy link
Copy Markdown
Author

Exception when (__ \ "fields" \ "customfield_10233" is not in the json

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment