Skip to content

Commit 85f2597

Browse files
committed
📝 Fix minor doc issue
1 parent 225bf9a commit 85f2597

2 files changed

Lines changed: 3 additions & 5 deletions

File tree

readme.md

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -102,7 +102,7 @@ app.Use(async (context, next) =>
102102
if (context.WebSockets.IsWebSocketRequest)
103103
{
104104
using var websocket = await context.WebSockets.AcceptWebSocketAsync();
105-
using var pipe = WebSocketPipe.Create(websocket, options);
105+
using var pipe = WebSocketPipe.Create(websocket, true);
106106
await Task.WhenAll(Echo(pipe), pipe.RunAsync(context.RequestAborted));
107107
}
108108
else

src/WebSocketPipe/readme.md

Lines changed: 2 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -96,10 +96,8 @@ app.Use(async (context, next) =>
9696
{
9797
if (context.WebSockets.IsWebSocketRequest)
9898
{
99-
using var websocket = await context.WebSockets.AcceptWebSocketAsync(
100-
context.WebSockets.WebSocketRequestedProtocols.FirstOrDefault());
101-
102-
using var pipe = WebSocketPipe.Create(websocket, options);
99+
using var websocket = await context.WebSockets.AcceptWebSocketAsync();
100+
using var pipe = WebSocketPipe.Create(websocket, true);
103101
await Task.WhenAll(Echo(pipe), pipe.RunAsync(context.RequestAborted));
104102
}
105103
else

0 commit comments

Comments
 (0)