One question is why not do like `/page/some` and `...
# ktor
o
One question is why not do like
/page/some
and
/course/some
? Another question, is why not have a single route and have an `if`/`when` inside it?
Copy code
get("/{entity}") {
   val entity = repository.findEntity(call.parameters["entity"]) ?: return call.respond(notfound)
   when (entity) {
      is Page -> …
      is Course -> …
  }
}