[Fix] Incorrect ConnectionState of a DiscordSocketClient casted to IDiscordClient/BaseSocketClient
This commit is contained in:
@@ -178,12 +178,13 @@ namespace Discord.Rest
|
||||
/// <inheritdoc />
|
||||
public Task<BotGateway> GetBotGatewayAsync(RequestOptions options = null)
|
||||
=> ClientHelper.GetBotGatewayAsync(this, options);
|
||||
|
||||
/// <inheritdoc />
|
||||
public virtual ConnectionState ConnectionState => ConnectionState.Disconnected;
|
||||
#endregion
|
||||
|
||||
#region IDiscordClient
|
||||
/// <inheritdoc />
|
||||
ConnectionState IDiscordClient.ConnectionState => ConnectionState.Disconnected;
|
||||
/// <inheritdoc />
|
||||
ISelfUser IDiscordClient.CurrentUser => CurrentUser;
|
||||
|
||||
/// <inheritdoc />
|
||||
|
||||
@@ -58,8 +58,8 @@ namespace Discord.WebSocket
|
||||
public override DiscordSocketRestClient Rest { get; }
|
||||
/// <summary> Gets the shard of this client. </summary>
|
||||
public int ShardId { get; }
|
||||
/// <summary> Gets the current connection state of this client. </summary>
|
||||
public ConnectionState ConnectionState => _connection.State;
|
||||
/// <inheritdoc />
|
||||
public override ConnectionState ConnectionState => _connection.State;
|
||||
/// <inheritdoc />
|
||||
public override int Latency { get; protected set; }
|
||||
/// <inheritdoc />
|
||||
|
||||
Reference in New Issue
Block a user