From 7e75cb3064729c03c79485d2c58c881f0cc6cf39 Mon Sep 17 00:00:00 2001 From: Burak Yigit Kaya Date: Wed, 28 Aug 2024 17:34:45 +0300 Subject: [PATCH] ignore incorrect TS error --- packages/overlay/src/lib/db.ts | 5 +++-- 1 file changed, 3 insertions(+), 2 deletions(-) diff --git a/packages/overlay/src/lib/db.ts b/packages/overlay/src/lib/db.ts index 8b49496e..ab23a002 100644 --- a/packages/overlay/src/lib/db.ts +++ b/packages/overlay/src/lib/db.ts @@ -4,12 +4,13 @@ export const OBJECT_STORE_NAME = 'events'; export const DB_VERSION = 2; function promiseWithResolvers() { - let reject: (value: T | PromiseLike) => void; - let resolve: (reason?: unknown) => void; + let resolve: (value: T | PromiseLike) => void; + let reject: (reason?: unknown) => void; const promise = new Promise((rs, rj) => { resolve = rs; reject = rj; }); + // @ts-expect-error ts2454 -- This is not a valid error as the promise constructor callback is executed immediately return { resolve, reject, promise }; }