From f2db48fdd92b258c4f7e98eab28472c488d5d9f2 Mon Sep 17 00:00:00 2001 From: juniwalk Date: Wed, 22 May 2024 11:15:50 +0200 Subject: [PATCH] Added docBlock for execute method --- src/Console/Tools/ProgressIndicator.php | 7 ++++++- 1 file changed, 6 insertions(+), 1 deletion(-) diff --git a/src/Console/Tools/ProgressIndicator.php b/src/Console/Tools/ProgressIndicator.php index af216fa..4616f2b 100644 --- a/src/Console/Tools/ProgressIndicator.php +++ b/src/Console/Tools/ProgressIndicator.php @@ -91,6 +91,11 @@ public function getStatus(): ?Status } + /** + * @template T of mixed + * @param callable(static): T $callback + * @return T|int + */ public function execute(string $message, callable $callback): mixed { $this->progress->setFormat("[%status%] %message%\n"); @@ -120,7 +125,7 @@ public function execute(string $message, callable $callback): mixed /** * @template T of mixed * @param T[] $values - * @param (callable(static, T, int|string): ?bool) $callback + * @param callable(static, T, int|string): mixed $callback */ public function iterate(iterable $values, callable $callback): void {