Created
August 26, 2019 07:57
-
-
Save rpiotrow/6846e4e31f444a7825ce9368e60e37e9 to your computer and use it in GitHub Desktop.
This file contains 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
when(val result = repository.findAll().attempt().unsafeRunSync()) { | |
is Either.Right -> call.respond(result.b) | |
else -> call.respond(HttpStatusCode.InternalServerError) | |
} |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment