Skip to content

Commit 5e2181d

Browse files
authored
Merge pull request #80 from syumai/release-0.15.0
Release 0.15.0
2 parents bdc15e5 + 392cd3e commit 5e2181d

9 files changed

Lines changed: 11 additions & 10 deletions

File tree

Makefile

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,4 +1,4 @@
1-
SHELL=/bin/bash
1+
SHELL=/usr/bin/env bash
22
TARGET_SRC=$(shell shopt -s globstar && ls ./**/*.{ts,js,tsx} | grep -v ./vendor | grep -v ./testdata)
33

44
test:

README.md

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -17,7 +17,7 @@ import {
1717
post,
1818
redirect,
1919
contentType,
20-
} from "https://denopkg.com/syumai/dinatra@0.14.0/mod.ts";
20+
} from "https://denopkg.com/syumai/dinatra@0.15.0/mod.ts";
2121

2222
app(
2323
get("/hello", () => "hello"),

dem.json

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -3,7 +3,7 @@
33
{
44
"protocol": "https",
55
"path": "deno.land/std",
6-
"version": "0.73.0",
6+
"version": "0.104.0",
77
"files": [
88
"/encoding/utf8.ts",
99
"/flags/mod.ts",

response.ts

Lines changed: 3 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,7 @@
1-
import { encode } from "./vendor/https/deno.land/std/encoding/utf8.ts";
21
import { ReadCloser } from "./io.ts";
32

3+
const encoder = new TextEncoder();
4+
45
// HeaderMap is a type of response headers.
56
type HeaderMap =
67
| Headers
@@ -56,7 +57,7 @@ export function processResponse(res: Response): HTTPResponse {
5657

5758
let body: Uint8Array | ReadCloser | Deno.Reader;
5859
if (typeof rawBody === "string") {
59-
body = encode(rawBody);
60+
body = encoder.encode(rawBody);
6061
} else {
6162
body = rawBody;
6263
}

serve_test.ts

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -134,7 +134,7 @@ for (const tc of testCases) {
134134
const contentLength = res.headers.get("content-length");
135135

136136
assertEquals(actual, tc.expected);
137-
assertEquals(contentLength, tc.expected.length.toString());
137+
assertEquals(contentLength, new Blob([tc.expected]).size.toString());
138138

139139
const { path, method } = tc.registered;
140140
app.unregister(path, method);
Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1 +1 @@
1-
export * from "https://deno.land/std@0.73.0/encoding/utf8.ts";
1+
export * from "https://deno.land/std@0.104.0/encoding/utf8.ts";
Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1 +1 @@
1-
export * from "https://deno.land/std@0.73.0/flags/mod.ts";
1+
export * from "https://deno.land/std@0.104.0/flags/mod.ts";
Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1 +1 @@
1-
export * from "https://deno.land/std@0.73.0/http/server.ts";
1+
export * from "https://deno.land/std@0.104.0/http/server.ts";
Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1 +1 @@
1-
export * from "https://deno.land/std@0.73.0/testing/asserts.ts";
1+
export * from "https://deno.land/std@0.104.0/testing/asserts.ts";

0 commit comments

Comments
 (0)