Last active
October 12, 2015 14:17
-
-
Save piuccio/93b281de8837fb55610c to your computer and use it in GitHub Desktop.
Handle query strings in scala
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
val queryString = {request.queryString.filter(_._2.exists(_.nonEmpty)).map { p => | |
"%s=%s".format(p._1, p._2.head.urlEncoded) | |
} ++ List(s"api-key=$key")}.mkString("&") |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment