r90957 MediaWiki - Code Review archive

Repository:MediaWiki
Revision:r90956‎ | r90957 | r90958 >
Date:14:10, 28 June 2011
Author:aaron
Status:ok
Tags:
Comment:
Removed raw Article->field accessing
Modified paths:
  • /trunk/phase3/includes/ExternalEdit.php (modified) (history)
  • /trunk/phase3/includes/ProtectionForm.php (modified) (history)
  • /trunk/phase3/includes/RawPage.php (modified) (history)
  • /trunk/phase3/includes/api/ApiDelete.php (modified) (history)

Diff [purge]

Index: trunk/phase3/includes/ProtectionForm.php
@@ -61,7 +61,7 @@
6262 global $wgUser;
6363 // Set instance variables.
6464 $this->mArticle = $article;
65 - $this->mTitle = $article->mTitle;
 65+ $this->mTitle = $article->getTitle();
6666 $this->mApplicableTypes = $this->mTitle->getRestrictionTypes();
6767
6868 // Check if the form should be disabled.
Index: trunk/phase3/includes/ExternalEdit.php
@@ -22,7 +22,7 @@
2323
2424 function __construct( $article, $mode ) {
2525 $this->mArticle =& $article;
26 - $this->mTitle =& $article->mTitle;
 26+ $this->mTitle = $article->getTitle();
2727 $this->mCharset = 'UTF-8';
2828 $this->mMode = $mode;
2929 }
Index: trunk/phase3/includes/api/ApiDelete.php
@@ -150,7 +150,7 @@
151151 if ( $article->doDeleteArticle( $reason, false, 0, true, $error ) ) {
152152 return array();
153153 } else {
154 - return array( array( 'cannotdelete', $article->mTitle->getPrefixedText() ) );
 154+ return array( array( 'cannotdelete', $article->getTitle()->getPrefixedText() ) );
155155 }
156156 }
157157
Index: trunk/phase3/includes/RawPage.php
@@ -28,7 +28,7 @@
2929
3030 $allowedCTypes = array( 'text/x-wiki', $wgJsMimeType, 'text/css', 'application/x-zope-edit' );
3131 $this->mArticle = $article;
32 - $this->mTitle = $article->mTitle;
 32+ $this->mTitle = $article->getTitle();
3333
3434 if( $request === false ) {
3535 $this->mRequest = $wgRequest;

Status & tagging log