Skip to content

Commit 55de842

Browse files
authored
Merge pull request #4 from pxlrbt/fix/stancl-tenancy
fix stancl tenancy command registration
2 parents f6fd710 + a96f910 commit 55de842

File tree

1 file changed

+1
-3
lines changed

1 file changed

+1
-3
lines changed

src/DatabaseStateServiceProvider.php

Lines changed: 1 addition & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -2,7 +2,6 @@
22

33
namespace pxlrbt\LaravelDatabaseState;
44

5-
use App\Console\Commands\SeedDatabaseStateCommand;
65
use Illuminate\Console\Events\CommandFinished;
76
use Illuminate\Support\Facades\Artisan;
87
use Illuminate\Support\Facades\Event;
@@ -26,7 +25,7 @@ public function configurePackage(Package $package): void
2625
Commands\SeedDatabaseStateCommand::class,
2726
]);
2827

29-
if (class_exists('\Stancl\Tenancy\Concerns\HasTenantOptions')) {
28+
if (trait_exists('\Stancl\Tenancy\Concerns\HasTenantOptions')) {
3029
$package->hasCommands([
3130
Commands\SeedTenantsDatabaseStateCommand::class,
3231
]);
@@ -45,7 +44,6 @@ public function packageBooted()
4544
);
4645
}
4746

48-
4947
public function runDatabaseStateSeeder(CommandFinished $event): void
5048
{
5149
if ($event->exitCode !== 0) {

0 commit comments

Comments
 (0)