From 96fe2d10a4da0521b7cd72d90fd42121f9311978 Mon Sep 17 00:00:00 2001 From: Yoshiya Hinosawa Date: Sun, 6 Oct 2019 01:02:34 +0900 Subject: Update eslint and @typescript-eslint (denoland/deno_std#621) Original: https://github.com/denoland/deno_std/commit/c3fe858f98565edbe8faeb3cf2e5b873304f4f6e --- ws/mod.ts | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) (limited to 'ws') diff --git a/ws/mod.ts b/ws/mod.ts index 8bd11aa0a..11e3ee23e 100644 --- a/ws/mod.ts +++ b/ws/mod.ts @@ -368,7 +368,7 @@ export function createSecAccept(nonce: string): string { const sha1 = new Sha1(); sha1.update(nonce + kGUID); const bytes = sha1.digest(); - return btoa(String.fromCharCode.apply(String, bytes)); + return btoa(String.fromCharCode(...bytes)); } /** Upgrade given TCP connection into websocket connection */ @@ -480,7 +480,7 @@ export async function connectWebSocket( headers: Headers = new Headers() ): Promise { const url = new URL(endpoint); - let { hostname } = url; + const { hostname } = url; let conn: Conn; if (url.protocol === "http:" || url.protocol === "ws:") { const port = parseInt(url.port || "80"); -- cgit v1.2.3