delete secret chat messages as well

This commit is contained in:
kosyak 2024-10-29 17:35:58 +07:00
parent 8772c9fd73
commit 4990ac0a23

View file

@ -2708,6 +2708,8 @@ public class XmppConnectionService extends Service {
public void destroyConversation(Conversation conversation) { public void destroyConversation(Conversation conversation) {
archiveConversation(conversation); archiveConversation(conversation);
final Runnable runnable = () -> { final Runnable runnable = () -> {
databaseBackend.deleteMessagesInConversation(conversation);
if (!databaseBackend.deleteConversation(conversation.getAccount(), conversation.getContactJid().asBareJid(), conversation.getNextCounterpart())) { if (!databaseBackend.deleteConversation(conversation.getAccount(), conversation.getContactJid().asBareJid(), conversation.getNextCounterpart())) {
Log.d(Config.LOGTAG, conversation.getJid().asBareJid() + ": unable to delete conversation"); Log.d(Config.LOGTAG, conversation.getJid().asBareJid() + ": unable to delete conversation");
} }