Add missing $popts parameter, and pass it from r79455
authorSam Reed <reedy@users.mediawiki.org>
Sat, 1 Jan 2011 23:06:04 +0000 (23:06 +0000)
committerSam Reed <reedy@users.mediawiki.org>
Sat, 1 Jan 2011 23:06:04 +0000 (23:06 +0000)
includes/api/ApiParse.php

index 6f3ddaa..42a0047 100644 (file)
@@ -97,7 +97,7 @@ class ApiParse extends ApiBase {
                                if ( $titleObj->getLatestRevID() === intval( $oldid ) )  {
                                        $articleObj = new Article( $titleObj );
 
-                                       $p_result = $this->getParsedSectionOrText( $articleObj, $titleObj, $pageid ) ;
+                                       $p_result = $this->getParsedSectionOrText( $articleObj, $titleObj, $popts, $pageid ) ;
 
                                } else {
                                        $text = $rev->getText( Revision::FOR_THIS_USER );
@@ -147,7 +147,7 @@ class ApiParse extends ApiBase {
                                        $oldid = $articleObj->getRevIdFetched();
                                }
 
-                               $p_result = $this->getParsedSectionOrText( $articleObj, $titleObj, $pageid ) ;
+                               $p_result = $this->getParsedSectionOrText( $articleObj, $titleObj, $popts, $pageid ) ;
                        }
                } else {
                        $titleObj = Title::newFromText( $title );
@@ -282,9 +282,10 @@ class ApiParse extends ApiBase {
         * @param  $articleObj Article
         * @param  $titleObj Title
         * @param  $pageId Int
+        * @param $pots ParserOptions
         * @return ParserOutput
         */
-       private function getParsedSectionOrText( $articleObj, $titleObj, $pageId = null ) {
+       private function getParsedSectionOrText( $articleObj, $titleObj, $popts, $pageId = null ) {
                global $wgParser;
 
                if ( $this->section !== false ) {