dwellman
03/15/2018, 5:36 PMfun FruitApp(): HttpHandler = ServerFilters.CatchLensFailure.then(
routes(
"/health" bind GET to { _: Request -> Response(OK) },
"/fruits" bind GET to { _: Request ->
Response(OK).with(
Body.json().toLens() of listOf("lemons" to 42.asJsonValue()).asJsonObject())
}
)
)