summaryrefslogtreecommitdiff
path: root/protocols
diff options
context:
space:
mode:
authorGeorge Hazan <george.hazan@gmail.com>2024-05-03 20:48:08 +0300
committerGeorge Hazan <george.hazan@gmail.com>2024-05-03 20:48:08 +0300
commit45ba633b285b3c66d5f563993aa06b3f58078e28 (patch)
tree93caeb985495e15fd23dbeb9417e7e0fa9ec605d /protocols
parentd61fb51575143353832cf3e4092be0e74d2d307a (diff)
fixes #4395 (Discord: "Change nickname" crashes private chats)
Diffstat (limited to 'protocols')
-rw-r--r--protocols/Discord/src/groupchat.cpp5
1 files changed, 4 insertions, 1 deletions
diff --git a/protocols/Discord/src/groupchat.cpp b/protocols/Discord/src/groupchat.cpp
index 22f2981858..f79cdfdb5c 100644
--- a/protocols/Discord/src/groupchat.cpp
+++ b/protocols/Discord/src/groupchat.cpp
@@ -73,8 +73,11 @@ int CDiscordProto::GroupchatMenuHook(WPARAM, LPARAM lParam)
if (pChat == nullptr)
return 0;
- if (gcmi->Type == MENU_ON_LOG)
+ if (gcmi->Type == MENU_ON_LOG) {
+ if (pChat->pGuild == nullptr)
+ sttLogListItems[0].uType = 0;
Chat_AddMenuItems(gcmi->hMenu, _countof(sttLogListItems), sttLogListItems, &g_plugin);
+ }
else if (gcmi->Type == MENU_ON_NICKLIST)
Chat_AddMenuItems(gcmi->hMenu, _countof(sttNicklistItems), sttNicklistItems, &g_plugin);