Skip to content

Commit 43e1fa3

Browse files
docs: remove await-thenable lint rule and fix invalid await usage (#1353)
1 parent 88ce5cd commit 43e1fa3

File tree

4 files changed

+3
-4
lines changed

4 files changed

+3
-4
lines changed

.oxlintrc.json

Lines changed: 0 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -10,7 +10,6 @@
1010
"typescript/unbound-method": "off",
1111
"typescript/no-floating-promises": "off",
1212
"typescript/no-implied-eval": "off",
13-
"typescript/await-thenable": "off",
1413
"typescript/restrict-template-expressions": "off",
1514
"typescript/no-base-to-string": "off",
1615
"typescript/no-redundant-type-constituents": "off",

src/utils/proxy.ts

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -18,7 +18,7 @@ export interface ProxyOptions {
1818
fetchOptions?: RequestInit & { duplex?: "half" | "full" };
1919
cookieDomainRewrite?: string | Record<string, string>;
2020
cookiePathRewrite?: string | Record<string, string>;
21-
onResponse?: (event: H3Event, response: Response) => void;
21+
onResponse?: (event: H3Event, response: Response) => void | Promise<void>;
2222
}
2323

2424
/**

test/bench/bench.test.ts

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -3,7 +3,7 @@ import { getRequests } from "./input.ts";
33
import { createInstances } from "./bench.impl.ts";
44

55
describe("benchmark", async () => {
6-
const instances = await createInstances();
6+
const instances = createInstances();
77

88
describe("app works as expected", () => {
99
for (const [name, _fetch] of instances) {

test/happydom.test.ts

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -6,7 +6,7 @@ describe("happydom", () => {
66
let h3: typeof import("../src/index.ts");
77

88
beforeAll(async () => {
9-
await GlobalRegistrator.register({
9+
GlobalRegistrator.register({
1010
url: "http://localhost:3000",
1111
width: 1920,
1212
height: 1080,

0 commit comments

Comments
 (0)