From: Aaron Schulz Date: Wed, 17 Jun 2009 21:11:29 +0000 (+0000) Subject: (bug 19214) Make sure new pages have page ID cached for getTitle() X-Git-Tag: 1.31.0-rc.0~41315 X-Git-Url: http://git.cyclocoop.org/%7B%24www_url%7Dadmin/compta/exercices/supprimer.php?a=commitdiff_plain;h=f741c09aa2591feec0e016b59fce10a817009654;p=lhc%2Fweb%2Fwiklou.git (bug 19214) Make sure new pages have page ID cached for getTitle() --- diff --git a/includes/RecentChange.php b/includes/RecentChange.php index 8e3f110744..2ca2f69c6d 100644 --- a/includes/RecentChange.php +++ b/includes/RecentChange.php @@ -119,6 +119,8 @@ class RecentChange public function &getTitle() { if( $this->mTitle === false ) { $this->mTitle = Title::makeTitle( $this->mAttribs['rc_namespace'], $this->mAttribs['rc_title'] ); + # Make sure the correct page ID is process cached + $this->mTitle->resetArticleID( $this->mAttribs['rc_cur_id'] ); } return $this->mTitle; } @@ -158,7 +160,7 @@ class RecentChange ## If we are using foreign keys, an entry of 0 for the page_id will fail, so use NULL if( $dbw->cascadingDeletes() and $this->mAttribs['rc_cur_id']==0 ) { - unset ( $this->mAttribs['rc_cur_id'] ); + unset( $this->mAttribs['rc_cur_id'] ); } # Insert new row