mirror of
https://github.com/simplex-chat/simplex-chat.git
synced 2026-11-04 15:07:32 +00:00
updateChatSettings read the contribution before and after from the chat it was passed, after the API call. After a resume SimpleXApp.updateChats lists new Chat objects while an open ChatView keeps the old one, so the stats it read could be stale and its settings never changed by updateContact/ updateGroup. And an item event processed during the call can already carry the new settings (addChatItem -> updateChatInfo), so reading the settings after the call gave before == after. The contribution before is now the listed chat's stats with the listed chat's settings from before the call, and after is the listed chat's, as the Kotlin updateChatSettings does. The "keep conversation" re-add in deleteContactChat likewise carries over the listed chat's stats, taken before removeChat, rather than the passed chat's.