From 7327eeff3cff845a7829ebd3752351ce8f5df0c3 Mon Sep 17 00:00:00 2001 From: Anton Golub Date: Sun, 22 Dec 2024 10:08:26 +0300 Subject: [PATCH] fix: suppress spinner in quiet mode --- src/goods.ts | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) diff --git a/src/goods.ts b/src/goods.ts index 476b991b2b..3276cb75a9 100644 --- a/src/goods.ts +++ b/src/goods.ts @@ -140,10 +140,10 @@ export async function retry( let callback: () => T let delayStatic = 0 let delayGen: Generator | undefined - if (typeof a == 'function') { + if (typeof a === 'function') { callback = a } else { - if (typeof a == 'object') { + if (typeof a === 'object') { delayGen = a } else { delayStatic = parseDuration(a) @@ -199,7 +199,7 @@ export async function spinner( callback = title title = '' } - if (process.env.CI) return callback!() + if ($.quiet || process.env.CI) return callback!() let i = 0 const spin = () =>