Hi!
I have a question about the routing.
I want to achieve something similar to
Copy code
routing {
route("/accounts") {
param("name") {
get {
findAccountsByName(...)
}
}
get {
findAllAccounts()
}
}
so that a
GET /accounts?name=me would execute findAccountsByName(...)
and
GET /accounts would execute findAllAccounts()
Apparently it always executes findAllAccounts(). Any idea why?
s
spand
12/09/2019, 12:42 PM
Theres also
optionalParam
c
coderskitchen
12/09/2019, 12:45 PM
Thanks 🙂
Tried out some things and finally got it working with