If I try to follow the example from the documentation it doesn't compile.
val route =
formFields('color, 'age.as[Int]) { (color, age) =>
complete(s"The color is '$color' and the age ten years ago was ${age -
10}")
}
I get the following error:
too many arguments for method formFields: (pdm:
akka.http.scaladsl.server.directives.FormFieldDirectives.FieldMagnet)pdm.Out
formFields('color, 'age.as[Int]) { (color, age) =>
^
one error found
Is the documentation wrong, or (more likely) what stupid mistake am I
making with this? In case it makes a difference here, I'm importing:
import akka.http.scaladsl.server._
import akka.http.scaladsl.server.Directives._
Cheers,
Ian.
--
>>>>>>>>>> Read the docs: http://akka.io/docs/
>>>>>>>>>> Check the FAQ:
>>>>>>>>>> http://doc.akka.io/docs/akka/current/additional/faq.html
>>>>>>>>>> Search the archives: https://groups.google.com/group/akka-user
---
You received this message because you are subscribed to the Google Groups "Akka
User List" group.
To unsubscribe from this group and stop receiving emails from it, send an email
to [email protected].
To post to this group, send email to [email protected].
Visit this group at http://groups.google.com/group/akka-user.
For more options, visit https://groups.google.com/d/optout.