Skip to content

Commit

Permalink
fix: restore name ensures fewer breakchanges
Browse files Browse the repository at this point in the history
  • Loading branch information
doghappy committed Jul 20, 2021
1 parent 35e8f3c commit c087107
Show file tree
Hide file tree
Showing 2 changed files with 5 additions and 5 deletions.
2 changes: 1 addition & 1 deletion src/SocketIOClient/SocketIO.cs
Original file line number Diff line number Diff line change
Expand Up @@ -172,7 +172,7 @@ public IWebSocketClient Socket
private void Initialize()
{
UrlConverter = new UrlConverter();
Socket = new DefaultClient();
Socket = new WebSocketClient.ClientWebSocket();
MessageProcessor = new EngineIOProtocolProcessor();
_packetId = -1;
_ackHandlers = new Dictionary<int, Action<SocketIOResponse>>();
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -10,9 +10,9 @@ namespace SocketIOClient.WebSocketClient
/// <summary>
/// Internally uses 'System.Net.WebSockets.ClientWebSocket' as websocket client
/// </summary>
public sealed class DefaultClient : IWebSocketClient
public sealed class ClientWebSocket : IWebSocketClient
{
public DefaultClient()
public ClientWebSocket()
{
ReceiveChunkSize = 1024 * 16;
ConnectionTimeout = TimeSpan.FromSeconds(10);
Expand All @@ -21,7 +21,7 @@ public DefaultClient()
public int ReceiveChunkSize { get; set; }
public TimeSpan ConnectionTimeout { get; set; }

ClientWebSocket _ws;
System.Net.WebSockets.ClientWebSocket _ws;
readonly SemaphoreSlim sendLock = new SemaphoreSlim(1, 1);
CancellationTokenSource _listenToken;

Expand All @@ -38,7 +38,7 @@ public DefaultClient()
public async Task ConnectAsync(Uri uri)
{
DisposeWebSocketIfNotNull();
_ws = new ClientWebSocket();
_ws = new System.Net.WebSockets.ClientWebSocket();

Config?.Invoke(_ws.Options);
var wsConnectionTokenSource = new CancellationTokenSource(ConnectionTimeout);
Expand Down

0 comments on commit c087107

Please sign in to comment.