Caffeinated\Modules\Console\Commands\ModuleMigrateRollbackCommand::fire PHP Method

fire() public method

Execute the console command.
public fire ( ) : mixed
return mixed
    public function fire()
    {
        if (!$this->confirmToProceed()) {
            return;
        }
        $this->migrator->setConnection($this->option('database'));
        $paths = $this->getMigrationPaths();
        $this->migrator->rollback($paths, ['pretend' => $this->option('pretend'), 'step' => (int) $this->option('step')]);
        foreach ($this->migrator->getNotes() as $note) {
            $this->output->writeln($note);
        }
    }