Skip to content

Instantly share code, notes, and snippets.

@xavi-
Created April 2, 2010 15:03
Show Gist options
  • Save xavi-/353226 to your computer and use it in GitHub Desktop.
Save xavi-/353226 to your computer and use it in GitHub Desktop.
val foo: Option[Set[Option[Char]]] = blah
val results = foo.map(_.map(_.map(bar).getOrElse(defVal))).getOrElse(Nil)
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment