r108442 MediaWiki - Code Review archive

Repository:MediaWiki
Revision:r108441‎ | r108442 | r108443 >
Date:18:13, 9 January 2012
Author:nikerabbit
Status:ok
Tags:
Comment:
$wgNarayamEnableByDefault was used for two different purposes.
Renamed the newer function to another name
Modified paths:
  • /trunk/extensions/Narayam/Narayam.hooks.php (modified) (history)
  • /trunk/extensions/Narayam/Narayam.php (modified) (history)
  • /trunk/extensions/Narayam/resources/ext.narayam.core.js (modified) (history)

Diff [purge]

Index: trunk/extensions/Narayam/Narayam.hooks.php
@@ -106,9 +106,8 @@
107107 * @return bool
108108 */
109109 public static function addDefaultOptions( &$defaultOptions ) {
110 - global $wgNarayamEnabledByDefault;
111 - // By default, the preference page option to enable Narayam is set to wgNarayamEnabledByDefault value.
112 - $defaultOptions['narayamEnable'] = $wgNarayamEnabledByDefault;
 110+ global $wgNarayamPreferenceDefaultValue;
 111+ $defaultOptions['narayamEnable'] = $wgNarayamPreferenceDefaultValue;
113112 return true;
114113 }
115114 }
Index: trunk/extensions/Narayam/resources/ext.narayam.core.js
@@ -460,7 +460,7 @@
461461 /**
462462 * Set up Narayam. This adds the scheme dropdown, binds the handlers
463463 * and initializes the enabled/disabled state and selected scheme
464 - * from a cookie or wgNarayamEnableByDefault
 464+ * from a cookie or wgNarayamEnabledByDefault
465465 */
466466 this.setup = function() {
467467 that.buildMenu();
Index: trunk/extensions/Narayam/Narayam.php
@@ -174,7 +174,7 @@
175175 // Autoloader
176176 $wgAutoloadClasses['NarayamHooks'] = $dir . '/Narayam.hooks.php';
177177
178 -$wgNarayamEnabledByDefault = true;
 178+$wgNarayamPreferenceDefaultValue = true;
179179
180180 // ResourceLoader module registration
181181 $narayamTpl = array(

Follow-up revisions

RevisionCommit summaryAuthorDate
r108444MFT r108442nikerabbit18:16, 9 January 2012

Status & tagging log