r83365 MediaWiki - Code Review archive

Repository:MediaWiki
Revision:r83364‎ | r83365 | r83366 >
Date:04:13, 6 March 2011
Author:bawolff
Status:ok (Comments)
Tags:
Comment:
If $wgEnotifMinorEdits=false, the enotifminoredits pref does nothing, so put it in $wgHiddenPrefs.

Its confusing to have it as an option, if its disabled, especially since there is no indication to the
user that it is disabled.
Modified paths:
  • /trunk/phase3/RELEASE-NOTES (modified) (history)
  • /trunk/phase3/includes/Setup.php (modified) (history)

Diff [purge]

Index: trunk/phase3/includes/Setup.php
@@ -238,6 +238,11 @@
239239 $wgHiddenPrefs[] = 'skin';
240240 }
241241
 242+# Doesn't make sense to have if disabled.
 243+if ( !$wgEnotifMinorEdits ) {
 244+ $wgHiddenPrefs[] = 'enotifminoredits';
 245+}
 246+
242247 if ( !$wgHtml5Version && $wgHtml5 && $wgAllowRdfaAttributes ) {
243248 # see http://www.w3.org/TR/rdfa-in-html/#document-conformance
244249 if ( $wgMimeType == 'application/xhtml+xml' ) {
Index: trunk/phase3/RELEASE-NOTES
@@ -162,6 +162,7 @@
163163 * Trim the form field for uploading by url to remove extra spaces which could
164164 cause confusing error messages.
165165 * (bug 27854) Http::isValidURI is way too lax.
 166+* Do not show enotifminoredits preference, if disabled by $wgEnotifMinorEdits.
166167
167168 === API changes in 1.18 ===
168169 * (bug 26339) Throw warning when truncating an overlarge API result

Comments

#Comment by Duplicatebug (talk | contribs)   18:24, 6 March 2011

Maybe move this to Preferences.php because other email settings are also checked there.

#Comment by Bawolff (talk | contribs)   18:28, 6 March 2011

I kind of think its nicer here, but don't really care much either way.

#Comment by Duplicatebug (talk | contribs)   20:29, 6 March 2011

That you decision, but having two places for that is also not good, I think.

#Comment by MaxSem (talk | contribs)   20:35, 6 March 2011

If this preference is already disabled in LocalSettings, you're just creating a duplicate entry. Will this affect anything?

#Comment by Bawolff (talk | contribs)   20:38, 6 March 2011

Well for example, on this wiki (mediawiki wiki) $wgEnotifMinorEdits is set to false, but the check box still appears on special:preferences, it just has no affect regardless of its checked statement. With this revision, the "E-mail me also for minor edits of pages" checkbox will no longer appear on special:preferences.

#Comment by Bawolff (talk | contribs)   20:40, 6 March 2011

ich, need to remember to preview: s/regardless of its checked statement/regardless of if it is checked or not/

Status & tagging log