mirror of
https://github.com/rhunk/SnapEnhance.git
synced 2025-04-29 22:24:35 +02:00
fix(core/notifications): resume coroutine
Signed-off-by: rhunk <101876869+rhunk@users.noreply.github.com>
This commit is contained in:
parent
f69f08c4ed
commit
a1dc03c958
@ -486,13 +486,12 @@ class Notifications : Feature("Notifications") {
|
||||
context.coroutineScope.launch(coroutineDispatcher) {
|
||||
suspendCoroutine { continuation ->
|
||||
conversationManager.fetchMessageByServerId(conversationId, serverMessageId.toLong(), onSuccess = {
|
||||
continuation.resumeWith(Result.success(Unit))
|
||||
if (it.senderId.toString() == context.database.myUserId) {
|
||||
continuation.resumeWith(Result.success(Unit))
|
||||
param.invokeOriginal()
|
||||
return@fetchMessageByServerId
|
||||
}
|
||||
context.coroutineScope.launch(coroutineDispatcher) {
|
||||
continuation.resumeWith(Result.success(Unit))
|
||||
onMessageReceived(notificationData, notificationType, it)
|
||||
}
|
||||
}, onError = {
|
||||
|
Loading…
x
Reference in New Issue
Block a user