diff --git a/src/Illuminate/Database/Console/Migrations/FreshCommand.php b/src/Illuminate/Database/Console/Migrations/FreshCommand.php index e319e74bc06a..f18036f72a15 100644 --- a/src/Illuminate/Database/Console/Migrations/FreshCommand.php +++ b/src/Illuminate/Database/Console/Migrations/FreshCommand.php @@ -61,7 +61,7 @@ public function handle() if ($this->laravel->bound(Dispatcher::class)) { $this->laravel[Dispatcher::class]->dispatch( - new DatabaseRefreshed + new DatabaseRefreshed($database, $this->needsSeeding()) ); } diff --git a/src/Illuminate/Database/Console/Migrations/RefreshCommand.php b/src/Illuminate/Database/Console/Migrations/RefreshCommand.php index 2073cd9977e6..5dff6467ac79 100755 --- a/src/Illuminate/Database/Console/Migrations/RefreshCommand.php +++ b/src/Illuminate/Database/Console/Migrations/RefreshCommand.php @@ -67,7 +67,7 @@ public function handle() if ($this->laravel->bound(Dispatcher::class)) { $this->laravel[Dispatcher::class]->dispatch( - new DatabaseRefreshed + new DatabaseRefreshed($database, $this->needsSeeding()) ); } diff --git a/src/Illuminate/Database/Events/DatabaseRefreshed.php b/src/Illuminate/Database/Events/DatabaseRefreshed.php index 5b1fb45856b3..f476c39e43b4 100644 --- a/src/Illuminate/Database/Events/DatabaseRefreshed.php +++ b/src/Illuminate/Database/Events/DatabaseRefreshed.php @@ -6,5 +6,17 @@ class DatabaseRefreshed implements MigrationEventContract { - // + /** + * Create a new event instance. + * + * @param string|null $database + * @param bool seeding + * @return void + */ + public function __construct( + public ?string $database = null, + public bool $seeding = false + ) { + // + } }