Check null on response back

This commit is contained in:
Sambo Chea 2021-05-21 10:36:04 +07:00
parent 813d0953e9
commit 6f6c592169

View File

@ -77,9 +77,13 @@ class TelegramProvider : MessageProvider, Loggable {
)
}
TelegramResponse(
response = response,
)
if (response != null) {
TelegramResponse(
response = response,
)
} else {
null
}
} catch (ex: Exception) {
log.error("[Telegram] Message send error: ${ex.message}!")
null