Conditions | 3 |
Paths | 3 |
Total Lines | 12 |
Code Lines | 7 |
Lines | 0 |
Ratio | 0 % |
Tests | 6 |
CRAP Score | 3.0261 |
Changes | 0 |
1 | <?php |
||
38 | 1 | protected static function detectCommandPath() |
|
39 | { |
||
40 | $paths = [ |
||
41 | 1 | static::normalizePath(static::getBasePath(),'vendor','bin','phinx'), |
|
42 | 1 | '~/.composer/vendor/bin/phinx' |
|
43 | ]; |
||
44 | 1 | foreach ($paths as $path) { |
|
45 | 1 | if (file_exists($path)) { |
|
46 | 1 | return $path; |
|
47 | } |
||
48 | } |
||
49 | return null; |
||
50 | } |
||
52 |