desktop: catch Toast exception (#3028)

This commit is contained in:
Stanislav Dmitrenko 2023-09-08 00:45:00 +03:00 committed by GitHub
parent 113a57c7c7
commit ad65622407
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23

View File

@ -104,7 +104,11 @@ object NtfManager {
actions.forEach {
builder.action(it.first, it.second)
}
prevNtfs.add(chatId to builder.toast())
try {
prevNtfs.add(chatId to builder.toast())
} catch (e: Exception) {
Log.e(TAG, e.stackTraceToString())
}
}
private fun prepareIconPath(icon: ImageBitmap?): String? = if (icon != null) {