Skip to content

Commit 12db9e6

Browse files
committed
Remove dummy wrapper. The evaluateSnippet return wasn't awaited so the catch part is never reached. It should throw and is tested for that
1 parent a80d5c9 commit 12db9e6

File tree

1 file changed

+0
-11
lines changed

1 file changed

+0
-11
lines changed

packages/theme/src/cli/utilities/repl/evaluator.ts

Lines changed: 0 additions & 11 deletions
Original file line numberDiff line numberDiff line change
@@ -17,17 +17,6 @@ export interface EvaluationConfig {
1717
}
1818

1919
export async function evaluate(config: EvaluationConfig): Promise<string | number | undefined> {
20-
try {
21-
return await evaluateSnippet(config)
22-
23-
// eslint-disable-next-line no-catch-all/no-catch-all, @typescript-eslint/no-explicit-any
24-
} catch (error: any) {
25-
outputInfo(outputContent`${outputToken.errorText(error.message)}`)
26-
outputDebug(error.stack || 'Error backtrace not found')
27-
}
28-
}
29-
30-
async function evaluateSnippet(config: EvaluationConfig): Promise<string | number | undefined> {
3120
return (
3221
(await evalResult(config)) ||
3322
(await evalContext(config)) ||

0 commit comments

Comments
 (0)