diff options
| author | Bartek IwaĆczuk <biwanczuk@gmail.com> | 2019-05-30 14:59:30 +0200 |
|---|---|---|
| committer | Ryan Dahl <ry@tinyclouds.org> | 2019-05-30 08:59:30 -0400 |
| commit | 50a79584cb12129b3db1ef3e0eb9d0c8b9f20b62 (patch) | |
| tree | ee9a90a8b8018c03b1e1a6ace07abdaa494ea90d /textproto/mod.ts | |
| parent | 80b3c486f6222f65b52eb2eca903b67312e8ce0c (diff) | |
chore: Implement strict mode (denoland/deno_std#453)
Original: https://github.com/denoland/deno_std/commit/be24677d15494e83eea2e99bfc5ccfdde31cb892
Diffstat (limited to 'textproto/mod.ts')
| -rw-r--r-- | textproto/mod.ts | 5 |
1 files changed, 3 insertions, 2 deletions
diff --git a/textproto/mod.ts b/textproto/mod.ts index 66f303905..6c4e42e51 100644 --- a/textproto/mod.ts +++ b/textproto/mod.ts @@ -82,7 +82,7 @@ export class TextProtoReader { throw new UnexpectedEOFError(); } else if (buf[0] == charCode(" ") || buf[0] == charCode("\t")) { throw new ProtocolError( - `malformed MIME header initial line: ${str(line)}` + `malformed MIME header initial line: ${str(line!)}` ); } @@ -140,7 +140,7 @@ export class TextProtoReader { const { line: l, more } = r; // Avoid the copy if the first call produced a full line. - if (!line && !more) { + if (!line! && !more) { // TODO(ry): // This skipSpace() is definitely misplaced, but I don't know where it // comes from nor how to fix it. @@ -150,6 +150,7 @@ export class TextProtoReader { return l; } + // @ts-ignore line = append(line, l); if (!more) { break; |
