From b4dfa57dac81f5ba1d52d1b3bb80625d00910178 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Frederic=20G=2E=20=C3=98stby?= Date: Sat, 26 Oct 2024 23:37:39 +0200 Subject: [PATCH] Update Spinner.php --- src/mako/cli/output/helpers/Spinner.php | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/src/mako/cli/output/helpers/Spinner.php b/src/mako/cli/output/helpers/Spinner.php index c0aa953cb..ad576d7b1 100644 --- a/src/mako/cli/output/helpers/Spinner.php +++ b/src/mako/cli/output/helpers/Spinner.php @@ -68,8 +68,6 @@ protected function spinner(string $message, string $template): void while (true) { $this->output->write("\r" . sprintf($template, $this->frames[$i++ % $frames]) . " {$message}"); - usleep(static::TIME_BETWEEN_REDRAW); - if (posix_kill(posix_getpid(), 0) === false) { break; } @@ -77,6 +75,8 @@ protected function spinner(string $message, string $template): void if (posix_getppid() === 1) { posix_kill(posix_getpid(), SIGKILL); } + + usleep(static::TIME_BETWEEN_REDRAW); } }