File tree Expand file tree Collapse file tree 1 file changed +2
-2
lines changed
Signal-Windows.Lib/Storage Expand file tree Collapse file tree 1 file changed +2
-2
lines changed Original file line number Diff line number Diff line change @@ -1000,7 +1000,7 @@ internal static void UpdateMessageRead(long index, SignalConversation conversati
10001000 if ( contact != null )
10011001 {
10021002 contact . LastSeenMessageIndex = index ;
1003- contact . UnreadCount = ( uint ) ( contact . MessagesCount - index ) ;
1003+ contact . UnreadCount = Math . Max ( contact . UnreadCount , ( uint ) ( contact . MessagesCount - index ) ) ;
10041004 }
10051005 }
10061006 else
@@ -1011,7 +1011,7 @@ internal static void UpdateMessageRead(long index, SignalConversation conversati
10111011 if ( group != null )
10121012 {
10131013 group . LastSeenMessageIndex = index ;
1014- group . UnreadCount = ( uint ) ( group . MessagesCount - index ) ;
1014+ group . UnreadCount = Math . Max ( group . UnreadCount , ( uint ) ( group . MessagesCount - index ) ) ;
10151015 }
10161016 }
10171017 ctx . SaveChanges ( ) ;
You can’t perform that action at this time.
0 commit comments