core: do not create decryption error chat items for earlier messages (#2189)

* core: do not create decryption error chat items for earlier messages

* do not report earlier error, mobile items, fix tests
This commit is contained in:
Evgeny Poberezkin authored and GitHub committed 2023-04-16 18:30:25 +01:00
1 parent 393238f47c
commit 5b4c183466
10 files changed
+31 -29

No files matched your search

+1 -5
View File
@@ -735,10 +735,7 @@ data CIContent (d :: MsgDirection) where
deriving instance Show (CIContent d)
data MsgDecryptError
= MDERatchetHeader
| MDEEarlier
| MDETooManySkipped
data MsgDecryptError = MDERatchetHeader | MDETooManySkipped
deriving (Eq, Show, Generic)
instance ToJSON MsgDecryptError where
@@ -954,7 +951,6 @@ msgDecryptErrorText err n =
where
errName = case err of
MDERatchetHeader -> "header"
MDEEarlier -> "earlier message"
MDETooManySkipped -> "too many skipped messages"
msgDirToModeratedContent_ :: SMsgDirection d -> CIContent d