Skip to content

refactor: Deprecated method of returning `void' in Сommands #9595

New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Closed
Closed
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
4 changes: 4 additions & 0 deletions system/CLI/BaseCommand.php
Original file line number Diff line number Diff line change
Expand Up @@ -102,6 +102,8 @@ public function __construct(LoggerInterface $logger, Commands $commands)
* @param array<int|string, string|null> $params
*
* @return int|void
*
* @deprecated 4.6.1 Using `void` as a return value is deprecated. Use `int` to return the exit code.
*/
abstract public function run(array $params);

Expand All @@ -113,6 +115,8 @@ abstract public function run(array $params);
* @return int|void
*
* @throws ReflectionException
*
* @deprecated 4.6.1 Using `void` as a return value is deprecated. Use `int` to return the exit code.
*/
protected function call(string $command, array $params = [])
{
Expand Down
2 changes: 2 additions & 0 deletions system/CLI/Console.php
Original file line number Diff line number Diff line change
Expand Up @@ -31,6 +31,8 @@ class Console
* @return int|void Exit code
*
* @throws Exception
*
* @deprecated 4.6.1 Using `void` as a return value is deprecated. Use `int` to return the exit code.
*/
public function run()
{
Expand Down
Loading