From c2219527b8e055afabef89d9fa17391e597e9db0 Mon Sep 17 00:00:00 2001 From: Keavon Chambers Date: Wed, 16 Nov 2022 20:50:53 -0800 Subject: [PATCH] Fix compilation after upgrading TypeScript --- frontend/src/utility-functions/panic-proxy.ts | 4 ++++ 1 file changed, 4 insertions(+) diff --git a/frontend/src/utility-functions/panic-proxy.ts b/frontend/src/utility-functions/panic-proxy.ts index 50ca858f..05a87e06 100644 --- a/frontend/src/utility-functions/panic-proxy.ts +++ b/frontend/src/utility-functions/panic-proxy.ts @@ -14,8 +14,12 @@ export function panicProxy(module: T): T { if (isClass) { // eslint-disable-next-line func-names return function (...args: unknown[]): unknown { + // All three of these comment lines are necessary to suppress errors at both compile time and while editing this file (@ts-expect-error doesn't work here while editing the file) + // eslint-disable-next-line @typescript-eslint/ban-ts-comment + // @ts-ignore // eslint-disable-next-line new-cap const result = new targetValue(...args); + return panicProxy(result); }; }