Skip to content

Renamed migrate methods with actions #116

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

Merged
merged 1 commit into from
Jan 21, 2023
Merged
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: 2 additions & 2 deletions src/Console/Actions.php
Original file line number Diff line number Diff line change
Expand Up @@ -4,7 +4,7 @@

use DragonCode\LaravelActions\Constants\Names;
use DragonCode\LaravelActions\Constants\Options;
use DragonCode\LaravelActions\Processors\Migrate as MigrateProcessor;
use DragonCode\LaravelActions\Processors\Actions as ActionsProcessor;
use DragonCode\LaravelActions\Processors\Processor;

class Actions extends Command
Expand All @@ -13,7 +13,7 @@ class Actions extends Command

protected $description = 'Run the actions';

protected Processor|string $processor = MigrateProcessor::class;
protected Processor|string $processor = ActionsProcessor::class;

protected bool $secure = false;

Expand Down
2 changes: 1 addition & 1 deletion src/Processors/Migrate.php → src/Processors/Actions.php
Original file line number Diff line number Diff line change
Expand Up @@ -13,7 +13,7 @@
use DragonCode\Support\Facades\Helpers\Str;
use Throwable;

class Migrate extends Processor
class Actions extends Processor
{
public function handle(): void
{
Expand Down
4 changes: 2 additions & 2 deletions src/Processors/Fresh.php
Original file line number Diff line number Diff line change
Expand Up @@ -12,7 +12,7 @@ class Fresh extends Processor
public function handle(): void
{
$this->drop();
$this->migrate();
$this->actions();
}

protected function drop(): void
Expand All @@ -22,7 +22,7 @@ protected function drop(): void
}
}

protected function migrate(): void
protected function actions(): void
{
$this->runCommand(Names::ACTIONS, [
'--' . Options::CONNECTION => $this->options->connection,
Expand Down
4 changes: 2 additions & 2 deletions src/Processors/Refresh.php
Original file line number Diff line number Diff line change
Expand Up @@ -15,7 +15,7 @@ public function handle(): void
$path = $this->options->path;

$this->runReset($connection, $path);
$this->runMigrate($connection, $path);
$this->runActions($connection, $path);
}

protected function runReset(?string $connection, ?string $path, bool $realPath = true): void
Expand All @@ -28,7 +28,7 @@ protected function runReset(?string $connection, ?string $path, bool $realPath =
]);
}

protected function runMigrate(?string $connection, ?string $path, bool $realPath = true): void
protected function runActions(?string $connection, ?string $path, bool $realPath = true): void
{
$this->runCommand(Names::ACTIONS, [
'--' . Options::CONNECTION => $connection,
Expand Down