diff --git a/.vscode/settings.json b/.vscode/settings.json index b599873..d8701b4 100644 --- a/.vscode/settings.json +++ b/.vscode/settings.json @@ -1,6 +1,5 @@ { "deno.enable": true, - "deno.lint": true, "eslint.nodePath": "./.eslint/node_modules", "eslint.options": { "overrideConfigFile": "./.eslint/eslint.config.mjs" diff --git a/deno.json b/deno.json index 4301f5a..fa21897 100644 --- a/deno.json +++ b/deno.json @@ -25,7 +25,7 @@ "lineWidth": 120 }, "tasks": { - "lint": "npx eslint -c .eslint/eslint.config.mjs .", + "lint": "deno lint && npx eslint -c .eslint/eslint.config.mjs .", "test": "export ENVIRONMENT=testing && deno test --allow-all --unstable-ffi" } } diff --git a/docker/libraries/container.ts b/docker/libraries/container.ts index f91edc9..a2934b1 100644 --- a/docker/libraries/container.ts +++ b/docker/libraries/container.ts @@ -1,3 +1,4 @@ +import type { Response } from "../../http/mod.ts"; import { type CreateExecOptions, Exec } from "./exec.ts"; import { modem } from "./modem.ts"; @@ -74,7 +75,7 @@ export class Container { until?: number; timestamps?: boolean; tail?: number | "all"; - } = {}) { + } = {}): Promise { return modem.request({ method: "GET", path: `/containers/${this.id}/logs`, query }); } diff --git a/http/libraries/response.ts b/http/libraries/response.ts index 2a3157b..dfa6f92 100644 --- a/http/libraries/response.ts +++ b/http/libraries/response.ts @@ -2,7 +2,7 @@ import { PROTOCOL } from "./common.ts"; export class Response { status: number = 500; - headers = new Map(); + headers: Map = new Map(); body = ""; constructor(readonly connection: Deno.Conn) {} @@ -44,7 +44,7 @@ export class Response { /** * Parsed JSON instance of the response body. */ - get json() { + get json(): Record { if (this.body === "") { return {}; }