diff --git a/src/client.ts b/src/client.ts index 86dd213f..e0c726bd 100644 --- a/src/client.ts +++ b/src/client.ts @@ -114,7 +114,7 @@ export class Client { if (!Array.isArray(value)) body.set(key, value); else { let index = 0; - value.forEach(item => body.set(`${key}[${index++}]`, item)); + for (const item of value) body.set(`${key}[${index++}]`, item); } const response = await fetch(new URL(endpoint, this.baseUrl), {method: "POST", headers: {"User-Agent": this.userAgent}, body}); diff --git a/tool/doc.js b/tool/doc.js index 5b14889f..ebea1c92 100644 --- a/tool/doc.js +++ b/tool/doc.js @@ -1,5 +1,5 @@ import {cpSync} from "node:fs"; // Builds the documentation. -["CHANGELOG.md", "LICENSE.md"].forEach(file => cpSync(file, `docs/${file.toLowerCase()}`)); +for (const file of ["CHANGELOG.md", "LICENSE.md"]) cpSync(file, `docs/${file.toLowerCase()}`); cpSync("docs/favicon.ico", "docs/api/favicon.ico");