Skip to content

Commit

Permalink
Fix DownloadVoiceStatesAsync and DownloadBoostSubscriptionsAsync are …
Browse files Browse the repository at this point in the history
…bypassed unexpectedly under some circumstance when GuildAvailable is triggered
  • Loading branch information
gehongyan committed Nov 20, 2022
1 parent b3d5080 commit ac7d069
Showing 1 changed file with 1 addition and 2 deletions.
3 changes: 1 addition & 2 deletions src/Kook.Net.WebSocket/KookSocketClient.cs
Original file line number Diff line number Diff line change
Expand Up @@ -120,8 +120,7 @@ private KookSocketClient(KookSocketConfig config, KookSocketApiClient client)
GuildAvailable += g =>
{
if (_guildDownloadTask?.IsCompleted == true
&& ConnectionState == ConnectionState.Connected
&& AlwaysDownloadUsers && !g.HasAllMembers)
&& ConnectionState == ConnectionState.Connected)
{
if (AlwaysDownloadUsers && !g.HasAllMembers)
_ = g.DownloadUsersAsync();
Expand Down

0 comments on commit ac7d069

Please sign in to comment.