Skip to content

Commit

Permalink
fix: add catch to listBatchDecryptedMessages method (#161)
Browse files Browse the repository at this point in the history
* fix: add catch to listBatchDecryptedMessages method

* add the fix to the decoded messages as well

* Revert "add the fix to the decoded messages as well"

This reverts commit d6eb8bd.

---------

Co-authored-by: Naomi Plasterer <[email protected]>
  • Loading branch information
Ezequiel Leanes and nplasterer authored Jan 24, 2024
1 parent 1a1e055 commit 3e94c70
Showing 1 changed file with 7 additions and 2 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -358,8 +358,13 @@ data class Conversations(
Log.d(TAG, "discarding message, unknown conversation $envelope")
return@mapNotNull null
}
val msg = conversation.decrypt(envelope)
msg
try {
val msg = conversation.decrypt(envelope)
msg
} catch (e: Exception) {
Log.e(TAG, "Error decrypting message: $envelope", e)
null
}
}
},
)
Expand Down

0 comments on commit 3e94c70

Please sign in to comment.