Browse Source

Minor edit

pull/22/merge
RogueException 9 years ago
parent
commit
19297ac623
1 changed files with 4 additions and 4 deletions
  1. +4
    -4
      src/Discord.Net.Audio/AudioClient.cs

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

@@ -210,13 +210,13 @@ namespace Discord.Audio
/// <param name="count">Number of bytes in this frame. </param>
public void Send(byte[] data, int offset, int count)
{
if (data == null) throw new ArgumentException(nameof(data));
if (count < 0) throw new ArgumentOutOfRangeException(nameof(count));
if (data == null) throw new ArgumentException(nameof(data));
if (count < 0) throw new ArgumentOutOfRangeException(nameof(count));
if (offset < 0) throw new ArgumentOutOfRangeException(nameof(count));
if (VoiceSocket.Server == null) return; //Has been closed
if (count == 0) return;

if (count != 0)
VoiceSocket.SendPCMFrames(data, offset, count);
VoiceSocket.SendPCMFrames(data, offset, count);
}

/// <summary> Clears the PCM buffer. </summary>


Loading…
Cancel
Save