Browse Source

Connection Closed errors should include the exception obj

tags/1.0-rc
RogueException 9 years ago
parent
commit
f8ae8bd9c3
3 changed files with 3 additions and 3 deletions
  1. +1
    -1
      src/Discord.Net/Audio/AudioClient.cs
  2. +1
    -1
      src/Discord.Net/Rpc/DiscordRpcClient.cs
  3. +1
    -1
      src/Discord.Net/WebSocket/DiscordSocketClient.cs

+ 1
- 1
src/Discord.Net/Audio/AudioClient.cs View File

@@ -86,7 +86,7 @@ namespace Discord.Audio
ApiClient.Disconnected += async ex => ApiClient.Disconnected += async ex =>
{ {
if (ex != null) if (ex != null)
await _audioLogger.WarningAsync($"Connection Closed: {ex.Message}").ConfigureAwait(false);
await _audioLogger.WarningAsync($"Connection Closed", ex).ConfigureAwait(false);
else else
await _audioLogger.WarningAsync($"Connection Closed").ConfigureAwait(false); await _audioLogger.WarningAsync($"Connection Closed").ConfigureAwait(false);
}; };


+ 1
- 1
src/Discord.Net/Rpc/DiscordRpcClient.cs View File

@@ -47,7 +47,7 @@ namespace Discord.Rpc
{ {
if (ex != null) if (ex != null)
{ {
await _rpcLogger.WarningAsync($"Connection Closed: {ex.Message}").ConfigureAwait(false);
await _rpcLogger.WarningAsync($"Connection Closed", ex).ConfigureAwait(false);
await StartReconnectAsync(ex).ConfigureAwait(false); await StartReconnectAsync(ex).ConfigureAwait(false);
} }
else else


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

@@ -92,7 +92,7 @@ namespace Discord.WebSocket
{ {
if (ex != null) if (ex != null)
{ {
await _gatewayLogger.WarningAsync($"Connection Closed: {ex.Message}").ConfigureAwait(false);
await _gatewayLogger.WarningAsync($"Connection Closed", ex).ConfigureAwait(false);
await StartReconnectAsync(ex).ConfigureAwait(false); await StartReconnectAsync(ex).ConfigureAwait(false);
} }
else else


Loading…
Cancel
Save