1
0
Fork 0
mirror of https://github.com/denoland/deno.git synced 2024-12-23 15:49:44 -05:00

ws: Add sec-websocket-version to handshake header (denoland/deno_std#468)

Original: 40f55da9cf
This commit is contained in:
hashrock 2019-05-31 00:51:47 +09:00 committed by Ryan Dahl
parent 2487c45547
commit aacf92eb11

View file

@ -423,6 +423,7 @@ async function handshake(
headers.set("upgrade", "websocket");
headers.set("connection", "upgrade");
headers.set("sec-websocket-key", key);
headers.set("sec-websocket-version", "13");
let headerStr = `GET ${pathname}?${searchParams || ""} HTTP/1.1\r\n`;
for (const [key, value] of headers) {