From 7d749a0474ecb2278fbebe2f7c02ec9447414fab Mon Sep 17 00:00:00 2001 From: Kurt Friars Date: Fri, 7 Feb 2025 11:07:37 -0500 Subject: [PATCH] Get rid of return types to stay consistent with the framework's schema builder --- src/Concerns/HasVersionedSchema.php | 26 +++++++++++++------------- 1 file changed, 13 insertions(+), 13 deletions(-) diff --git a/src/Concerns/HasVersionedSchema.php b/src/Concerns/HasVersionedSchema.php index 580c855..48d924c 100644 --- a/src/Concerns/HasVersionedSchema.php +++ b/src/Concerns/HasVersionedSchema.php @@ -74,7 +74,7 @@ public function versionFromMigration(string $migration): ?Version /** * {@inheritDoc} */ - public function create($table, Closure $callback): void + public function create($table, Closure $callback) { $original = $table; @@ -90,7 +90,7 @@ public function create($table, Closure $callback): void /** * {@inheritDoc} */ - public function createForModel(string $class, Closure $callback): void + public function createForModel(string $class, Closure $callback) { if (! is_a($class, Model::class, true)) { throw new InvalidArgumentException('Models used in migrations must be instances of '.Model::class.'.'); @@ -111,7 +111,7 @@ public function createForModel(string $class, Closure $callback): void /** * {@inheritDoc} */ - public function drop($table): void + public function drop($table) { if ($active = $this->versions->active()) { $table = $active->addTablePrefix($table); @@ -123,7 +123,7 @@ public function drop($table): void /** * {@inheritDoc} */ - public function dropForModel($class): void + public function dropForModel($class) { if (! is_a($class, Model::class, true)) { throw new InvalidArgumentException('Models used in migrations must be instances of '.Model::class.'.'); @@ -137,7 +137,7 @@ public function dropForModel($class): void /** * {@inheritDoc} */ - public function dropIfExists($table): void + public function dropIfExists($table) { if ($active = $this->versions->active()) { $table = $active->addTablePrefix($table); @@ -149,7 +149,7 @@ public function dropIfExists($table): void /** * {@inheritDoc} */ - public function table($table, Closure $callback): void + public function table($table, Closure $callback) { if ($active = $this->versions->active()) { $table = $active->addTablePrefix($table); @@ -161,7 +161,7 @@ public function table($table, Closure $callback): void /** * {@inheritDoc} */ - public function model(string $class, Closure $callback): void + public function model(string $class, Closure $callback) { if (! is_a($class, Model::class, true)) { throw new InvalidArgumentException('Models used in migrations must be instances of '.Model::class.'.'); @@ -173,7 +173,7 @@ public function model(string $class, Closure $callback): void /** * {@inheritDoc} */ - public function rename($from, $to): void + public function rename($from, $to) { if ($active = $this->versions->active()) { $from = $active->addTablePrefix($from); @@ -186,7 +186,7 @@ public function rename($from, $to): void /** * {@inheritDoc} */ - public function hasTable($table): bool + public function hasTable($table) { if ($active = $this->versions->active()) { $table = $active->addTablePrefix($table); @@ -198,7 +198,7 @@ public function hasTable($table): bool /** * {@inheritDoc} */ - public function hasColumn($table, $column): bool + public function hasColumn($table, $column) { if ($active = $this->versions->active()) { $table = $active->addTablePrefix($table); @@ -210,7 +210,7 @@ public function hasColumn($table, $column): bool /** * {@inheritDoc} */ - public function hasColumns($table, array $columns): bool + public function hasColumns($table, array $columns) { if ($active = $this->versions->active()) { $table = $active->addTablePrefix($table); @@ -222,7 +222,7 @@ public function hasColumns($table, array $columns): bool /** * {@inheritDoc} */ - public function dropColumns($table, $columns): void + public function dropColumns($table, $columns) { if ($active = $this->versions->active()) { $table = $active->addTablePrefix($table); @@ -246,7 +246,7 @@ public function getColumnType($table, $column, $fullDefinition = false) /** * {@inheritDoc} */ - public function getColumnListing($table): array + public function getColumnListing($table) { if ($active = $this->versions->active()) { $table = $active->addTablePrefix($table);