From 7bb05873f0ea3cbb0c7418e3a3390a3f68136e15 Mon Sep 17 00:00:00 2001 From: "j.stein" Date: Sat, 12 Feb 2022 16:53:23 +0100 Subject: [PATCH] Fix issues --- src/Commands/Run.php | 3 ++- src/Concerns/HasATenantsOption.php | 4 ++-- 2 files changed, 4 insertions(+), 3 deletions(-) diff --git a/src/Commands/Run.php b/src/Commands/Run.php index 4e622c6b..f3b2197f 100644 --- a/src/Commands/Run.php +++ b/src/Commands/Run.php @@ -5,9 +5,11 @@ declare(strict_types=1); namespace Stancl\Tenancy\Commands; use Illuminate\Console\Command; +use Stancl\Tenancy\Concerns\HasATenantsOption; class Run extends Command { + use HasATenantsOption; /** * The console command description. * @@ -21,7 +23,6 @@ class Run extends Command * @var string */ protected $signature = "tenants:run {commandname : The command's name.} - {--tenants=* : The tenant(s) to run the command for. Default: all} {--argument=* : The arguments to pass to the command. Default: none} {--option=* : The options to pass to the command. Default: none}"; diff --git a/src/Concerns/HasATenantsOption.php b/src/Concerns/HasATenantsOption.php index 055c6cd4..120bb21c 100644 --- a/src/Concerns/HasATenantsOption.php +++ b/src/Concerns/HasATenantsOption.php @@ -27,9 +27,9 @@ trait HasATenantsOption ->cursor(); } - protected function withPending(): bool + protected function withPending(): ?bool { - return $this->option('with-pending'); + return $this->option('with-pending') ? true : null; } public function __construct()