r100883 MediaWiki - Code Review archive

Repository:MediaWiki
Revision:r100882‎ | r100883 | r100884 >
Date:21:48, 26 October 2011
Author:aaron
Status:ok (Comments)
Tags:
Comment:
Fixed process cache for bad images when the list is empty
Modified paths:
  • /trunk/phase3/includes/ImageFunctions.php (modified) (history)

Diff [purge]

Index: trunk/phase3/includes/ImageFunctions.php
@@ -19,7 +19,7 @@
2020 * @return bool
2121 */
2222 function wfIsBadImage( $name, $contextTitle = false ) {
23 - static $badImages = false;
 23+ static $badImages = null;
2424 wfProfileIn( __METHOD__ );
2525
2626 # Handle redirects
@@ -35,7 +35,7 @@
3636 return $bad;
3737 }
3838
39 - if( !$badImages ) {
 39+ if( $badImages === null ) {
4040 # Build the list now
4141 $badImages = array();
4242 $lines = explode( "\n", wfMsgForContentNoTrans( 'bad_image_list' ) );

Sign-offs

UserFlagDate
Nikerabbitinspected06:42, 27 October 2011

Follow-up revisions

RevisionCommit summaryAuthorDate
r100932Disabled "bad image" tests which made totally broken assumptions about how/wh...aaron01:36, 27 October 2011

Comments

#Comment by Johnduhart (talk | contribs)   22:19, 26 October 2011

Status & tagging log