summaryrefslogtreecommitdiff
path: root/protocols/Discord
diff options
context:
space:
mode:
Diffstat (limited to 'protocols/Discord')
-rw-r--r--protocols/Discord/src/proto.cpp9
1 files changed, 5 insertions, 4 deletions
diff --git a/protocols/Discord/src/proto.cpp b/protocols/Discord/src/proto.cpp
index 61ed2237bf..b9acdbf101 100644
--- a/protocols/Discord/src/proto.cpp
+++ b/protocols/Discord/src/proto.cpp
@@ -355,10 +355,11 @@ MCONTACT CDiscordProto::AddToList(int flags, PROTOSEARCHRESULT *psr)
MEVENT CDiscordProto::RecvMsg(MCONTACT hContact, PROTORECVEVENT *evt)
{
- T2Utf szResUtf((const wchar_t*)evt->lParam);
- evt->pCustomData = (char*)szResUtf;
- evt->cbCustomDataSize = (DWORD)mir_strlen(szResUtf);
- return CSuper::RecvMsg(hContact, evt);
+ MEVENT hDbEvent = CSuper::RecvMsg(hContact, evt);
+ if (hDbEvent && evt->lParam)
+ db_event_setId(m_szModuleName, hDbEvent, T2Utf((const wchar_t*)evt->lParam));
+
+ return hDbEvent;
}
////////////////////////////////////////////////////////////////////////////////////////