diff --git a/lib/src/omemo/sessionmanager.dart b/lib/src/omemo/sessionmanager.dart index ce10a7d..6ba00a3 100644 --- a/lib/src/omemo/sessionmanager.dart +++ b/lib/src/omemo/sessionmanager.dart @@ -381,7 +381,7 @@ class OmemoSessionManager { } else { keyAndHmac = await ratchet.ratchetDecrypt(message, decodedRawKey); } - } on InvalidMessageHMACException { + } catch (_) { await _restoreRatchet(ratchetKey, oldRatchet); rethrow; }