diff options
author | George Hazan <ghazan@miranda.im> | 2022-10-31 22:28:18 +0300 |
---|---|---|
committer | George Hazan <ghazan@miranda.im> | 2022-10-31 22:28:18 +0300 |
commit | 3b3e0ae47024887e32db4cb657b8dcdb11d66d4c (patch) | |
tree | c2bdad260c0fd9cc7afc66d78a10a7bd3491e6a9 | |
parent | f2eb27dfc34bdc7657e9f032161d80b0a8feef26 (diff) |
fixes #3230 (WhatsApp: при удалении учётной записи остаётся кэш)
-rw-r--r-- | protocols/WhatsApp/src/proto.cpp | 8 | ||||
-rw-r--r-- | protocols/WhatsApp/src/proto.h | 1 |
2 files changed, 9 insertions, 0 deletions
diff --git a/protocols/WhatsApp/src/proto.cpp b/protocols/WhatsApp/src/proto.cpp index e28d53a8a2..7a74dadba5 100644 --- a/protocols/WhatsApp/src/proto.cpp +++ b/protocols/WhatsApp/src/proto.cpp @@ -103,6 +103,14 @@ WhatsAppProto::~WhatsAppProto() } ///////////////////////////////////////////////////////////////////////////////////////// +// OnErase - remove temporary folder for account + +void WhatsAppProto::OnErase() +{ + DeleteDirectoryTreeW(CMStringW(VARSW(L"%miranda_userdata%")) + L"\\" + _A2T(m_szModuleName), false); +} + +///////////////////////////////////////////////////////////////////////////////////////// // OnModulesLoaded emulator for an account void WhatsAppProto::OnModulesLoaded() diff --git a/protocols/WhatsApp/src/proto.h b/protocols/WhatsApp/src/proto.h index bddf804014..521bea0f3c 100644 --- a/protocols/WhatsApp/src/proto.h +++ b/protocols/WhatsApp/src/proto.h @@ -414,6 +414,7 @@ public: int SetStatus(int iNewStatus) override; int UserIsTyping(MCONTACT hContact, int type) override; + void OnErase() override; void OnModulesLoaded() override; // Services //////////////////////////////////////////////////////////////////////////// |