public SocketGuildUser CurrentUser => Discord.StateManager.GetMember(Discord.CurrentUser.Id, Id);
public SocketGuildUser CurrentUser => Discord.StateManager.TryGetMemberStore(Id, out var store) ? store.Get(Discord.CurrentUser.Id) : null;
/// <summary>
/// <summary>
/// Gets the built-in role containing all users in this guild.
/// Gets the built-in role containing all users in this guild.
/// </summary>
/// </summary>
@@ -356,7 +356,7 @@ namespace Discord.WebSocket
/// <returns>
/// <returns>
/// A collection of guild users found within this guild.
/// A collection of guild users found within this guild.
/// </returns>
/// </returns>
public IReadOnlyCollection<SocketGuildUser> Users => Discord.StateManager.GetMembers(Id).Cast<SocketGuildUser>().ToImmutableArray();
public IReadOnlyCollection<SocketGuildUser> Users => Discord.StateManager.TryGetMemberStore(Id, out var store) ? store.GetAll().ToImmutableArray() : ImmutableArray<SocketGuildUser>.Empty;
internal override Lazy<SocketPresence> Presence { get { return new Lazy<SocketPresence>(() => new SocketPresence(UserStatus.Offline, null, null)); } set { } }
internal override Lazy<SocketGlobalUser> GlobalUser { get => new Lazy<SocketGlobalUser>(() => null); set { } }
internal override LazyCached<SocketPresence> Presence { get { return new(SocketPresence.Default); } set { } }
internal override LazyCached<SocketGlobalUser> GlobalUser { get => new(null); set { } }
internal override Lazy<SocketPresence> Presence { get { return new Lazy<SocketPresence>(() => new SocketPresence(UserStatus.Offline, null, null)); } set { } }
internal override Lazy<SocketGlobalUser> GlobalUser { get => new Lazy<SocketGlobalUser>(() => null); set { } }
internal override LazyCached<SocketPresence> Presence { get { return new(SocketPresence.Default); } set { } }
internal override LazyCached<SocketGlobalUser> GlobalUser { get => new(null); set { } }
Thank you for your continuous support to the Openl Qizhi Community AI Collaboration Platform. In order to protect your usage rights and ensure network security, we updated the Openl Qizhi Community AI Collaboration Platform Usage Agreement in January 2024. The updated agreement specifies that users are prohibited from using intranet penetration tools. After you click "Agree and continue", you can continue to use our services. Thank you for your cooperation and understanding.