r64263 MediaWiki - Code Review archive

Repository:MediaWiki
Revision:r64262‎ | r64263 | r64264 >
Date:16:15, 27 March 2010
Author:ialex
Status:ok
Tags:
Comment:
* (bug 22876) Avoid possible PHP Notice if $wgDefaultUserOptions is not correctly set

Per Nikerabbit, use User::getDefaultOption()
Modified paths:
  • /trunk/phase3/RELEASE-NOTES (modified) (history)
  • /trunk/phase3/languages/Language.php (modified) (history)

Diff [purge]

Index: trunk/phase3/languages/Language.php
@@ -1367,8 +1367,7 @@
13681368 if( $usePrefs ) {
13691369 $datePreference = $wgUser->getDatePreference();
13701370 } else {
1371 - $options = User::getDefaultOptions();
1372 - $datePreference = (string)$options['date'];
 1371+ $datePreference = (string)User::getDefaultOption( 'date' );
13731372 }
13741373 } else {
13751374 $datePreference = (string)$usePrefs;
Index: trunk/phase3/RELEASE-NOTES
@@ -60,6 +60,8 @@
6161 * (bug 22940) Namespace aliases pointing to main namespace don't work
6262 * (bug 15810) blocked admins can no longer block/unblock other users, nor
6363 themselves unless they are given the 'unblockself' permission.
 64+* (bug 22876) Avoid possible PHP Notice if $wgDefaultUserOptions is not
 65+ correctly set
6466
6567 == API changes in 1.17 ==
6668 * (bug 22738) Allow filtering by action type on query=logevent

Status & tagging log