Removed raw Article->field accessing
authorAaron Schulz <aaron@users.mediawiki.org>
Tue, 28 Jun 2011 14:10:55 +0000 (14:10 +0000)
committerAaron Schulz <aaron@users.mediawiki.org>
Tue, 28 Jun 2011 14:10:55 +0000 (14:10 +0000)
includes/ExternalEdit.php
includes/ProtectionForm.php
includes/RawPage.php
includes/api/ApiDelete.php

index 094ae8f..58e57e4 100644 (file)
@@ -22,7 +22,7 @@ class ExternalEdit {
 
        function __construct( $article, $mode ) {
                $this->mArticle =& $article;
-               $this->mTitle =& $article->mTitle;
+               $this->mTitle = $article->getTitle();
                $this->mCharset = 'UTF-8';
                $this->mMode = $mode;
        }
index 10b7fd9..5f8ab3f 100644 (file)
@@ -61,7 +61,7 @@ class ProtectionForm {
                global $wgUser;
                // Set instance variables.
                $this->mArticle = $article;
-               $this->mTitle = $article->mTitle;
+               $this->mTitle = $article->getTitle();
                $this->mApplicableTypes = $this->mTitle->getRestrictionTypes();
                
                // Check if the form should be disabled.
index f37ef99..4d5af46 100644 (file)
@@ -28,7 +28,7 @@ class RawPage {
 
                $allowedCTypes = array( 'text/x-wiki', $wgJsMimeType, 'text/css', 'application/x-zope-edit' );
                $this->mArticle = $article;
-               $this->mTitle = $article->mTitle;
+               $this->mTitle = $article->getTitle();
 
                if( $request === false ) {
                        $this->mRequest = $wgRequest;
index 06e0c64..979e8e1 100644 (file)
@@ -150,7 +150,7 @@ class ApiDelete extends ApiBase {
                if ( $article->doDeleteArticle( $reason, false, 0, true, $error ) ) {
                        return array();
                } else {
-                       return array( array( 'cannotdelete', $article->mTitle->getPrefixedText() ) );
+                       return array( array( 'cannotdelete', $article->getTitle()->getPrefixedText() ) );
                }
        }