r89696 MediaWiki - Code Review archive

Repository:MediaWiki
Revision:r89695‎ | r89696 | r89697 >
Date:21:32, 7 June 2011
Author:platonides
Status:ok (Comments)
Tags:
Comment:
Translate extension wants to keep 1.16 compatible.
Use GAID_FOR_UPDATE and keep the define there so that it won't break in 1.18
Follow up r74035.
Modified paths:
  • /trunk/extensions/Translate/tag/SpecialPageTranslationMovePage.php (modified) (history)

Diff [purge]

Index: trunk/extensions/Translate/tag/SpecialPageTranslationMovePage.php
@@ -8,6 +8,11 @@
99 * @license http://www.gnu.org/copyleft/gpl.html GNU General Public License 2.0 or later
1010 */
1111
 12+if ( !defined( GAID_FOR_UPDATE ) ) {
 13+ /* Backwards-compatible define for 1.17+ (see r75379) */
 14+ define( 'GAID_FOR_UPDATE', Title::GAID_FOR_UPDATE );
 15+}
 16+
1217 /**
1318 * Overrides Special:Movepage to to allow renaming a page translation page and
1419 * all related translations and derivative pages.
@@ -370,10 +375,10 @@
371376 MoveJob::forceRedirects( true );
372377
373378 $newTpage = TranslatablePage::newFromTitle( $this->newTitle );
374 - $newTpage->addReadyTag( $this->newTitle->getLatestRevId( Title::GAID_FOR_UPDATE ) );
 379+ $newTpage->addReadyTag( $this->newTitle->getLatestRevId( GAID_FOR_UPDATE ) );
375380
376381 if ( $newTpage->getMarkedTag() === $oldLatest ) {
377 - $newTpage->addMarkedTag( $this->newTitle->getLatestRevId( Title::GAID_FOR_UPDATE ) );
 382+ $newTpage->addMarkedTag( $this->newTitle->getLatestRevId( GAID_FOR_UPDATE ) );
378383 }
379384
380385 MessageGroups::clearCache();

Follow-up revisions

RevisionCommit summaryAuthorDate
r89729Fix r89696 - caused fatal errornikerabbit13:31, 8 June 2011

Past revisions this follows-up on

RevisionCommit summaryAuthorDate
r74035Follow up r74034: Refactor GAID_FOR_UPDATE into Title::GAID_FOR_UPDATE. Yay l...demon19:14, 30 September 2010

Comments

#Comment by Nikerabbit (talk | contribs)   21:37, 7 June 2011

Thanks a lot!

#Comment by Platonides (talk | contribs)   21:49, 7 June 2011

No problem, Niklas :)

Status & tagging log