Completed
Pull Request — master (#56)
by
unknown
03:52
created
SemanticFormsSelect.php 1 patch
Spacing   +9 added lines, -9 removed lines patch added patch discarded remove patch
@@ -15,7 +15,7 @@  discard block
 block discarded – undo
15 15
 	 */
16 16
 	public static function initExtension() {
17 17
 
18
-		define( 'SFS_VERSION', '2.0.1' );
18
+		define('SFS_VERSION', '2.0.1');
19 19
 
20 20
 
21 21
 		// Api modules
@@ -26,7 +26,7 @@  discard block
 block discarded – undo
26 26
 
27 27
 		// Register resource files
28 28
 		$GLOBALS['wgResourceModules']['ext.sf_select.scriptselect'] = array(
29
-			'localBasePath' => __DIR__ ,
29
+			'localBasePath' => __DIR__,
30 30
 			'remoteExtPath' => 'SemanticFormsSelect',
31 31
 			'position' => 'bottom',
32 32
 			'scripts' => array(
@@ -43,12 +43,12 @@  discard block
 block discarded – undo
43 43
 	 */
44 44
 	public static function onExtensionFunction() {
45 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.' );
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 48
 		}
49 49
 
50
-		if ( isset( $GLOBALS['wgPageFormsFormPrinter'] )) {
51
-			$GLOBALS['wgPageFormsFormPrinter']->setInputTypeHook( 'SF_Select', '\SFS\SemanticFormsSelect::init', array() );
50
+		if (isset($GLOBALS['wgPageFormsFormPrinter'])) {
51
+			$GLOBALS['wgPageFormsFormPrinter']->setInputTypeHook('SF_Select', '\SFS\SemanticFormsSelect::init', array());
52 52
 		}
53 53
 	}
54 54
 
@@ -59,13 +59,13 @@  discard block
 block discarded – undo
59 59
 	 *
60 60
 	 * @return string|null
61 61
 	 */
62
-	public static function getVersion( $dependency = null ) {
62
+	public static function getVersion($dependency = null) {
63 63
 
64
-		if ( $dependency === null && defined( 'SFS_VERSION' ) ) {
64
+		if ($dependency === null && defined('SFS_VERSION')) {
65 65
 			return SFS_VERSION;
66 66
 		}
67 67
 
68
-		if ( $dependency === 'PageForms' && defined( 'PF_VERSION' ) ) {
68
+		if ($dependency === 'PageForms' && defined('PF_VERSION')) {
69 69
 			return PF_VERSION;
70 70
 		}
71 71
 
Please login to merge, or discard this patch.