From 403e019da36c2b6c015fc7bcd404ffb5c613d5f9 Mon Sep 17 00:00:00 2001 From: Arthur Fiorette Date: Sat, 7 Sep 2024 00:53:09 -0300 Subject: [PATCH] code --- src/Error/Errors.ts | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/src/Error/Errors.ts b/src/Error/Errors.ts index 70539485b..ef4161f5d 100644 --- a/src/Error/Errors.ts +++ b/src/Error/Errors.ts @@ -118,6 +118,6 @@ export class UnhandledError extends BaseError { static from(message: string, node?: ts.Node, cause?: unknown) { // This might be called deeply inside the parser chain // this ensures it doesn't end up with error.cause.cause.cause... - return cause instanceof UnhandledError ? cause : new UnhandledError(message, node, cause); + return cause instanceof BaseError ? cause : new UnhandledError(message, node, cause); } }