Skip to content

Commit 629f28c

Browse files
committed
Fix error-display and spinner type safety
1 parent d56cc6a commit 629f28c

File tree

2 files changed

+2
-2
lines changed

2 files changed

+2
-2
lines changed

src/utils/error-display.mts

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -58,7 +58,7 @@ export function formatErrorForDisplay(
5858
// Handle error causes (chain of errors).
5959
if (error.cause && showStack) {
6060
const causeLines = []
61-
let currentCause = error.cause
61+
let currentCause: unknown = error.cause
6262
let depth = 1
6363

6464
while (currentCause && depth <= 5) {

src/utils/spinner.mts

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -38,7 +38,7 @@ function renderSpinner(state: SpinnerState): void {
3838
}
3939

4040
const frame = SPINNER_FRAMES[state.frame % SPINNER_FRAMES.length]
41-
const text = `${colors.cyan(frame)} ${state.message}`
41+
const text = `${colors.cyan(frame ?? '')} ${state.message}`
4242

4343
// Clear line and write spinner.
4444
process.stderr.write(`\r\x1b[K${text}`)

0 commit comments

Comments
 (0)