Browse Source

init

pull/2271/head
Quin Lynch 3 years ago
parent
commit
b6cb80ca95
1 changed files with 3 additions and 1 deletions
  1. +3
    -1
      src/Discord.Net.WebSocket/DiscordSocketClient.cs

+ 3
- 1
src/Discord.Net.WebSocket/DiscordSocketClient.cs View File

@@ -2331,7 +2331,9 @@ namespace Discord.WebSocket

SocketUser user = data.User.IsSpecified
? State.GetOrAddUser(data.User.Value.Id, (_) => SocketGlobalUser.Create(this, State, data.User.Value))
: guild?.AddOrUpdateUser(data.Member.Value); // null if the bot scope isn't set, so the guild cannot be retrieved.
: guild != null
? guild.AddOrUpdateUser(data.Member.Value) // null if the bot scope isn't set, so the guild cannot be retrieved.
: State.GetOrAddUser(data.Member.Value.User.Id, (_) => SocketGlobalUser.Create(this, State, data.Member.Value.User));

SocketChannel channel = null;
if(data.ChannelId.IsSpecified)


Loading…
Cancel
Save