| Conditions | 2 |
| Paths | 1 |
| Total Lines | 11 |
| Code Lines | 8 |
| Lines | 0 |
| Ratio | 0 % |
| Tests | 9 |
| CRAP Score | 2.004 |
| Changes | 0 | ||
| 1 | <?php |
||
| 12 | 7 | public function run() |
|
| 13 | { |
||
| 14 | 7 | $routines = (new ReflectionClass( __CLASS__ ))->getMethods( ReflectionMethod::IS_PROTECTED ); |
|
| 15 | 7 | $routines = array_column( $routines, 'name' ); |
|
| 16 | 7 | natsort( $routines ); |
|
| 17 | 7 | array_walk( $routines, function( $routine ) { |
|
| 18 | 7 | $version = str_replace( strtolower( __CLASS__ ).'_', '', $routine ); |
|
| 19 | 7 | if( version_compare( glsr()->version, $version, '>=' ))return; |
|
| 20 | call_user_func( [$this, $routine] ); |
||
| 21 | 7 | }); |
|
| 22 | 7 | $this->updateVersion(); |
|
| 23 | 7 | } |
|
| 42 |