mirror of
https://github.com/dotnet/MQTTnet.git
synced 2026-10-18 18:43:10 +08:00
Refactor code
This commit is contained in:
@@ -28,10 +28,11 @@ namespace MQTTnet.Implementations
|
||||
{
|
||||
uri += ":" + options.Port;
|
||||
}
|
||||
|
||||
|
||||
_webSocket = new ClientWebSocket();
|
||||
_webSocket.Options.KeepAliveInterval = options.KeepAlivePeriod;
|
||||
await _webSocket.ConnectAsync(new Uri(uri), CancellationToken.None).ConfigureAwait(false);
|
||||
|
||||
RawReceiveStream = new WebSocketStream(_webSocket);
|
||||
}
|
||||
|
||||
|
||||
Reference in New Issue
Block a user