@@ -15,7 +15,7 @@ discard block |
||
15 | 15 | */ |
16 | 16 | public static function initExtension() { |
17 | 17 | |
18 | - define( 'SFS_VERSION', '2.0.0-alpha' ); |
|
18 | + define('SFS_VERSION', '2.0.0-alpha'); |
|
19 | 19 | |
20 | 20 | // Api modules |
21 | 21 | $GLOBALS['wgAPIModules']['sformsselect'] = 'SFS\ApiSemanticFormsSelect'; |
@@ -25,10 +25,10 @@ discard block |
||
25 | 25 | |
26 | 26 | // Register resource files |
27 | 27 | $GLOBALS['wgResourceModules']['ext.sf_select.scriptselect'] = array( |
28 | - 'localBasePath' => __DIR__ , |
|
28 | + 'localBasePath' => __DIR__, |
|
29 | 29 | 'remoteExtPath' => 'SemanticFormsSelect', |
30 | 30 | 'position' => 'bottom', |
31 | - 'scripts' => array( 'res/scriptSelect.js' ), |
|
31 | + 'scripts' => array('res/scriptSelect.js'), |
|
32 | 32 | 'dependencies' => array( |
33 | 33 | 'ext.pageforms.main' |
34 | 34 | ) |
@@ -40,12 +40,12 @@ discard block |
||
40 | 40 | */ |
41 | 41 | public static function onExtensionFunction() { |
42 | 42 | |
43 | - if ( !defined( 'PF_VERSION' ) ) { |
|
44 | - 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.' ); |
|
43 | + if (!defined('PF_VERSION')) { |
|
44 | + 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.'); |
|
45 | 45 | } |
46 | 46 | |
47 | - if ( isset( $GLOBALS['wgPageFormsFormPrinter'] )) { |
|
48 | - $GLOBALS['wgPageFormsFormPrinter']->setInputTypeHook( 'SF_Select', '\SFS\SemanticFormsSelect::init', array() ); |
|
47 | + if (isset($GLOBALS['wgPageFormsFormPrinter'])) { |
|
48 | + $GLOBALS['wgPageFormsFormPrinter']->setInputTypeHook('SF_Select', '\SFS\SemanticFormsSelect::init', array()); |
|
49 | 49 | } |
50 | 50 | } |
51 | 51 | |
@@ -55,7 +55,7 @@ discard block |
||
55 | 55 | * @return string|null |
56 | 56 | */ |
57 | 57 | public static function getVersion() { |
58 | - return is_string( SFS_VERSION ) ? SFS_VERSION : null; |
|
58 | + return is_string(SFS_VERSION) ? SFS_VERSION : null; |
|
59 | 59 | } |
60 | 60 | |
61 | 61 | } |