r77848 MediaWiki - Code Review archive

Repository:MediaWiki
Revision:r77847‎ | r77848 | r77849 >
Date:01:08, 6 December 2010
Author:vyznev
Status:ok
Tags:
Comment:
Fix bug causing rebuildFileCache.php to create inappropriate cache files for redirects. (Actually, it would be better to create _correct_ cache files for them instead, but this doesn't seem to be something the file cache was designed to do, so I'll leave it for later.)
Modified paths:
  • /trunk/phase3/RELEASE-NOTES (modified) (history)
  • /trunk/phase3/includes/Article.php (modified) (history)

Diff [purge]

Index: trunk/phase3/includes/Article.php
@@ -3920,7 +3920,7 @@
39213921 $cacheable = false;
39223922
39233923 if ( HTMLFileCache::useFileCache() ) {
3924 - $cacheable = $this->getID() && !$this->mRedirectedFrom;
 3924+ $cacheable = $this->getID() && !$this->mRedirectedFrom && !$this->mTitle->isRedirect();
39253925 // Extension may have reason to disable file caching on some pages.
39263926 if ( $cacheable ) {
39273927 $cacheable = wfRunHooks( 'IsFileCacheable', array( &$this ) );
Index: trunk/phase3/RELEASE-NOTES
@@ -458,6 +458,7 @@
459459 absolute URLs in the sitemap index (as required e.g. by Google)
460460 * Partial workaround for bug 6220: at least make files on shared repositories
461461 show up as (struck-out) bluelinks instead of redlinks on Special:WantedFiles
 462+* rebuildFileCache.php no longer creates inappropriate cache files for redirects
462463
463464 === API changes in 1.17 ===
464465 * (bug 22738) Allow filtering by action type on query=logevent.

Status & tagging log