Merge "Add function to clear mPreparedEdit, to use in cases of mutable content"
[lhc/web/wiklou.git] / includes / api / ApiFormatBase.php
index e8e6acf..c1817fa 100644 (file)
@@ -43,9 +43,9 @@ abstract class ApiFormatBase extends ApiBase {
        public function __construct( $main, $format ) {
                parent::__construct( $main, $format );
 
-               $this->mIsHtml = ( substr( $format, - 2, 2 ) === 'fm' ); // ends with 'fm'
+               $this->mIsHtml = ( substr( $format, -2, 2 ) === 'fm' ); // ends with 'fm'
                if ( $this->mIsHtml ) {
-                       $this->mFormat = substr( $format, 0, - 2 ); // remove ending 'fm'
+                       $this->mFormat = substr( $format, 0, -2 ); // remove ending 'fm'
                } else {
                        $this->mFormat = $format;
                }
@@ -170,12 +170,12 @@ abstract class ApiFormatBase extends ApiBase {
 ?>
 <br />
 <small>
-You are looking at the HTML representation of the <?php echo( $this->mFormat ); ?> format.<br />
+You are looking at the HTML representation of the <?php echo $this->mFormat; ?> format.<br />
 HTML is good for debugging, but is unsuitable for application use.<br />
 Specify the format parameter to change the output format.<br />
-To see the non HTML representation of the <?php echo( $this->mFormat ); ?> format, set format=<?php echo( strtolower( $this->mFormat ) ); ?>.<br />
+To see the non HTML representation of the <?php echo $this->mFormat; ?> format, set format=<?php echo strtolower( $this->mFormat ); ?>.<br />
 See the <a href='https://www.mediawiki.org/wiki/API'>complete documentation</a>, or
-<a href='<?php echo( $script ); ?>'>API help</a> for more information.
+<a href='<?php echo $script; ?>'>API help</a> for more information.
 </small>
 <pre style='white-space: pre-wrap;'>
 <?php
@@ -360,8 +360,8 @@ class ApiFormatFeedWrapper extends ApiFormatBase {
 
        /**
         * This class expects the result data to be in a custom format set by self::setResult()
-        * $result['_feed']             - an instance of one of the $wgFeedClasses classes
-        * $result['_feeditems']        - an array of FeedItem instances
+        * $result['_feed'] - an instance of one of the $wgFeedClasses classes
+        * $result['_feeditems'] - an array of FeedItem instances
         */
        public function execute() {
                $data = $this->getResultData();