1
0
mirror of https://github.com/InsanusMokrassar/TelegramBotAPI.git synced 2024-06-01 23:45:25 +00:00

Update Webhook.kt

This commit is contained in:
InsanusMokrassar 2022-05-14 02:31:36 +06:00 committed by GitHub
parent e9ff93cde1
commit 82c6eda0b7
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23

View File

@ -49,10 +49,11 @@ fun Route.includeWebhookHandlingInRoute(
transformer(update) transformer(update)
}.onSuccess { }.onSuccess {
call.respond(HttpStatusCode.OK) call.respond(HttpStatusCode.OK)
}.onFailure {
call.respond(HttpStatusCode.InternalServerError)
} }
} catch (e: Throwable) { } catch (e: Throwable) {
exceptionsHandler ?.invoke(e) exceptionsHandler ?.invoke(e)
call.respond(HttpStatusCode.InternalServerError)
} }
} }
} }