| Conditions | 2 |
| Paths | 2 |
| Total Lines | 17 |
| Lines | 0 |
| Ratio | 0 % |
| Changes | 0 | ||
| 1 | <?php |
||
| 3 | public static function onRegistration() { |
||
| 4 | if ( !class_exists( ParamProcessor\Processor::class ) ) { |
||
| 5 | throw new Exception( 'Validator depends on the ParamProcessor library.' ); |
||
| 6 | } |
||
| 7 | |||
| 8 | define( 'Validator_VERSION', '2.2.5' ); |
||
| 9 | define( 'ParamProcessor_VERSION', Validator_VERSION ); // @deprecated since 1.0 |
||
| 10 | |||
| 11 | global $wgDataValues, $wgParamDefinitions; |
||
| 12 | |||
| 13 | $wgDataValues['mediawikititle'] = ParamProcessor\MediaWikiTitleValue::class; |
||
| 14 | |||
| 15 | $wgParamDefinitions['title'] = [ |
||
| 16 | 'string-parser' => ParamProcessor\TitleParser::class, |
||
| 17 | 'validator' => ValueValidators\TitleValidator::class, |
||
| 18 | ]; |
||
| 19 | } |
||
| 20 | |||
| 46 |