Unverified Commit 5cd0b0c4 authored by JJ Kasper's avatar JJ Kasper Committed by GitHub

Update resetting log for spinners (#8995)

parent 5f1bcd32
......@@ -21,6 +21,8 @@ export default function createSpinner(
...options,
}).start()
// Add capturing of console.log/warn/error to allow pausing
// the spinner before logging and then restarting spinner after
const origLog = console.log
const origWarn = console.warn
const origError = console.error
......@@ -39,6 +41,8 @@ export default function createSpinner(
const resetLog = () => {
console.log = origLog
console.warn = origWarn
console.error = origError
}
spinner.stop = (): ora.Ora => {
origStop()
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment