From 4587927bb51e66934cc78409a05c6667e3b97daf Mon Sep 17 00:00:00 2001 From: George Hazan Date: Wed, 5 Dec 2018 17:24:36 +0300 Subject: Discord: fix for missing channel user creation --- protocols/Discord/src/dispatch.cpp | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) (limited to 'protocols/Discord') diff --git a/protocols/Discord/src/dispatch.cpp b/protocols/Discord/src/dispatch.cpp index 43b5233729..0ae576870b 100644 --- a/protocols/Discord/src/dispatch.cpp +++ b/protocols/Discord/src/dispatch.cpp @@ -407,7 +407,7 @@ void CDiscordProto::OnCommandMessage(const JSONNode &pRoot, bool bIsNew) pm = new CDiscordGuildMember(userId); pm->wszNick = pRoot["nick"].as_mstring(); if (pm->wszNick.IsEmpty()) - pm->wszNick = pRoot["user"]["username"].as_mstring() + L"#" + pRoot["user"]["discriminator"].as_mstring(); + pm->wszNick = pRoot["author"]["username"].as_mstring() + L"#" + pRoot["author"]["discriminator"].as_mstring(); pGuild->arChatUsers.insert(pm); debugLogA("add missing user to chat: id=%lld, nick=%S", userId, pm->wszNick.c_str()); -- cgit v1.2.3