summaryrefslogtreecommitdiff
path: root/http_test.ts
diff options
context:
space:
mode:
authorKevin (Kun) "Kassimo" Qian <kevinkassimo@gmail.com>2018-12-06 16:08:21 -0500
committerRyan Dahl <ry@tinyclouds.org>2018-12-06 16:08:21 -0500
commit17c255581dbeff6bad6fe385b6cdee174e3f93ae (patch)
treec3f6f89811323b1cd9874a76821d641845238cc4 /http_test.ts
parenta34bc9040dc86efe5dfa9e89a6d4daadb425891d (diff)
Unblock server on multiple HTTP requests (denoland/deno_std#3)
Original: https://github.com/denoland/deno_std/commit/1bf555ab2f9c6074b07697d72cb93f276ecf5bb1
Diffstat (limited to 'http_test.ts')
-rw-r--r--http_test.ts3
1 files changed, 1 insertions, 2 deletions
diff --git a/http_test.ts b/http_test.ts
index e6cb87f01..b0007a892 100644
--- a/http_test.ts
+++ b/http_test.ts
@@ -5,8 +5,7 @@ const addr = "0.0.0.0:8000";
const s = serve(addr);
console.log(`listening on http://${addr}/`);
-const body = (new TextEncoder()).encode("Hello World\n");
-
+const body = new TextEncoder().encode("Hello World\n");
async function main() {
for await (const req of s) {