-
Notifications
You must be signed in to change notification settings - Fork 890
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Upgrade to cakephp-cs 5 and add type declarations
- Loading branch information
1 parent
394fb1c
commit b6646f1
Showing
115 changed files
with
1,129 additions
and
1,024 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,4 +1,5 @@ | ||
<?php | ||
declare(strict_types=1); | ||
|
||
/** | ||
* MIT License | ||
|
@@ -23,8 +24,6 @@ | |
|
||
/** | ||
* Abstract command, contains bootstrapping info | ||
* | ||
* @author Rob Morgan <[email protected]> | ||
*/ | ||
abstract class AbstractCommand extends Command | ||
{ | ||
|
@@ -52,22 +51,22 @@ abstract class AbstractCommand extends Command | |
/** | ||
* @var \Phinx\Config\ConfigInterface|null | ||
*/ | ||
protected $config; | ||
protected ?ConfigInterface $config = null; | ||
|
||
/** | ||
* @var \Phinx\Db\Adapter\AdapterInterface | ||
*/ | ||
protected $adapter; | ||
protected AdapterInterface $adapter; | ||
|
||
/** | ||
* @var \Phinx\Migration\Manager | ||
*/ | ||
protected $manager; | ||
protected Manager $manager; | ||
|
||
/** | ||
* @var int | ||
*/ | ||
protected $verbosityLevel = OutputInterface::OUTPUT_NORMAL | OutputInterface::VERBOSITY_NORMAL; | ||
protected int $verbosityLevel = OutputInterface::OUTPUT_NORMAL | OutputInterface::VERBOSITY_NORMAL; | ||
|
||
/** | ||
* Exit code for when command executes successfully | ||
|
@@ -235,7 +234,7 @@ public function setManager(Manager $manager) | |
*/ | ||
public function getManager(): ?Manager | ||
{ | ||
return $this->manager; | ||
return $this->manager ?? null; | ||
} | ||
|
||
/** | ||
|
@@ -342,7 +341,7 @@ protected function loadConfig(InputInterface $input, OutputInterface $output): v | |
*/ | ||
protected function loadManager(InputInterface $input, OutputInterface $output): void | ||
{ | ||
if ($this->getManager() === null) { | ||
if (!isset($this->manager)) { | ||
$manager = new Manager($this->getConfig(), $input, $output); | ||
$manager->setVerbosityLevel($this->verbosityLevel); | ||
$container = $this->getConfig()->getContainer(); | ||
|
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Oops, something went wrong.