| Conditions | 3 |
| Paths | 3 |
| Total Lines | 10 |
| Code Lines | 5 |
| Lines | 0 |
| Ratio | 0 % |
| Changes | 0 | ||
| 1 | <?php |
||
| 44 | public static function onExtensionFunction() { |
||
| 45 | |||
| 46 | if ( !defined( 'PF_VERSION' ) ) { |
||
| 47 | die( '<b>Error:</b><a href="https://github.com/SemanticMediaWiki/SemanticFormsSelect/">Semantic Forms Select</a> requires the <a href="https://www.mediawiki.org/wiki/Extension:PageForms">Page Forms</a> extension. Please install and activate this extension first.' ); |
||
| 48 | } |
||
| 49 | |||
| 50 | if ( isset( $GLOBALS['wgPageFormsFormPrinter'] )) { |
||
| 51 | $GLOBALS['wgPageFormsFormPrinter']->setInputTypeHook( 'SF_Select', '\SFS\SemanticFormsSelect::init', array() ); |
||
| 52 | } |
||
| 53 | } |
||
| 54 | |||
| 76 |
You can fix this by adding a namespace to your class:
When choosing a vendor namespace, try to pick something that is not too generic to avoid conflicts with other libraries.