[libraries/ktextaddons] textautogeneratetext/core: Remove pending chat too

Laurent Montel <[email protected]>
Newsgroups gmane.comp.kde.cvs
Message-ID <[email protected]>
Git commit 3e67d199d8b5fed5e493b71b10169f7efa413d92 by Laurent Montel.
Committed on 16/08/2026 at 12:27.
Pushed by mlaurent into branch 'master'.

Remove pending chat too

M  +2    -0    textautogeneratetext/core/textautogeneratemanager.cpp

https://invent.kde.org/libraries/ktextaddons/-/commit/3e67d199d8b5fed5e493b71b10169f7efa413d92

diff --git a/textautogeneratetext/core/textautogeneratemanager.cpp b/textautogeneratetext/core/textautogeneratemanager.cpp
index 2d0032c00..5eec2c3b4 100644
--- a/textautogeneratetext/core/textautogeneratemanager.cpp
+++ b/textautogeneratetext/core/textautogeneratemanager.cpp
@@ -480,6 +480,8 @@ void TextAutoGenerateManager::removeDiscussion(const QByteArray &chatId)
 {
     if (!chatId.isEmpty()) {
         mTextAutoGenerateChatsModel->removeDiscussion(chatId);
+        // Drop the pending typed info too, otherwise it survives the discussion it belongs to.
+        mTextAutoGenerateChatSettings->remove(chatId);
         if (mSaveInDatabase) {
             mDatabaseManager->deleteChat(chatId);
         }
lmpx.com only provides a reader for public news (NNTP) servers. It is not affiliated with the servers or forums shown here and is not responsible for the content of articles, which is written by their respective authors.