Skip to content

Commit

Permalink
Rename AutoUpdateRolePositions
Browse files Browse the repository at this point in the history
  • Loading branch information
gehongyan committed May 16, 2024
1 parent 02386ac commit 304a64f
Show file tree
Hide file tree
Showing 3 changed files with 3 additions and 3 deletions.
2 changes: 1 addition & 1 deletion samples/Kook.Net.Samples.SimpleBot/Program.cs
Original file line number Diff line number Diff line change
Expand Up @@ -19,7 +19,7 @@
MessageCacheSize = 100,
LogLevel = LogSeverity.Debug,
AutoUpdateChannelPositions = true,
AutoUpdateGuildRoles = true
AutoUpdateRolePositions = true
};

// 在使用完 Kook.Net 的客户端后,建议在应用程序的生命周期结束时进行 Dispose 操作
Expand Down
2 changes: 1 addition & 1 deletion src/Kook.Net.WebSocket/KookSocketClient.Messages.cs
Original file line number Diff line number Diff line change
Expand Up @@ -955,7 +955,7 @@ await UnknownGuildAsync(gatewayEvent.ExtraData.Type, gatewayEvent.TargetId, gate
|| before.BufferBoostSubscriptionCount != guild.BufferBoostSubscriptionCount))
await guild.DownloadBoostSubscriptionsAsync().ConfigureAwait(false);

if (BaseConfig.AutoUpdateGuildRoles)
if (BaseConfig.AutoUpdateRolePositions)
{
IEnumerable<Role> models = await ApiClient.GetGuildRolesAsync(guild.Id)
.FlattenAsync()
Expand Down
2 changes: 1 addition & 1 deletion src/Kook.Net.WebSocket/KookSocketConfig.cs
Original file line number Diff line number Diff line change
Expand Up @@ -171,7 +171,7 @@ public int JoinedGuildDataFetchingRetryDelay
/// <summary>
/// Gets or sets whether to update guild role positions via API when <see cref="BaseSocketClient.GuildUpdated"/> fires.
/// </summary>
public bool AutoUpdateGuildRoles { get; set; } = false;
public bool AutoUpdateRolePositions { get; set; } = false;

/// <summary>
/// Gets or sets whether to update guild channels via API when gateway publishes sort_channel events.
Expand Down

0 comments on commit 304a64f

Please sign in to comment.