Merge "FauxRequest: Avoid header leak"
authorjenkins-bot <jenkins-bot@gerrit.wikimedia.org>
Wed, 16 Sep 2015 17:02:57 +0000 (17:02 +0000)
committerGerrit Code Review <gerrit@wikimedia.org>
Wed, 16 Sep 2015 17:02:57 +0000 (17:02 +0000)
includes/GlobalFunctions.php
includes/specials/SpecialEditTags.php
includes/specials/SpecialExport.php

index 2852561..f2e37d5 100644 (file)
@@ -171,6 +171,7 @@ if ( !function_exists( 'hash_equals' ) ) {
  *
  * @param string $ext Name of the extension to load
  * @param string|null $path Absolute path of where to find the extension.json file
+ * @since 1.25
  */
 function wfLoadExtension( $ext, $path = null ) {
        if ( !$path ) {
@@ -191,6 +192,7 @@ function wfLoadExtension( $ext, $path = null ) {
  *
  * @see wfLoadExtension
  * @param string[] $exts Array of extension names to load
+ * @since 1.25
  */
 function wfLoadExtensions( array $exts ) {
        global $wgExtensionDirectory;
@@ -206,6 +208,7 @@ function wfLoadExtensions( array $exts ) {
  * @see wfLoadExtension
  * @param string $skin Name of the extension to load
  * @param string|null $path Absolute path of where to find the skin.json file
+ * @since 1.25
  */
 function wfLoadSkin( $skin, $path = null ) {
        if ( !$path ) {
@@ -220,6 +223,7 @@ function wfLoadSkin( $skin, $path = null ) {
  *
  * @see wfLoadExtensions
  * @param string[] $skins Array of extension names to load
+ * @since 1.25
  */
 function wfLoadSkins( array $skins ) {
        global $wgStyleDirectory;
index 54f50d9..d2b2e70 100644 (file)
@@ -123,7 +123,7 @@ class SpecialEditTags extends UnlistedSpecialPage {
 
                // Either submit or create our form
                if ( $this->isAllowed && $this->submitClicked ) {
-                       $this->submit( $request );
+                       $this->submit();
                } else {
                        $this->showForm();
                }
index 69b795d..39c4d77 100644 (file)
@@ -30,7 +30,6 @@
  */
 class SpecialExport extends SpecialPage {
        private $curonly, $doExport, $pageLinkDepth, $templates;
-       private $images;
 
        public function __construct() {
                parent::__construct( 'Export' );
@@ -46,7 +45,6 @@ class SpecialExport extends SpecialPage {
                $this->doExport = false;
                $request = $this->getRequest();
                $this->templates = $request->getCheck( 'templates' );
-               $this->images = $request->getCheck( 'images' ); // Doesn't do anything yet
                $this->pageLinkDepth = $this->validateLinkDepth(
                        $request->getIntOrNull( 'pagelink-depth' )
                );
@@ -279,13 +277,6 @@ class SpecialExport extends SpecialPage {
                }
 
                $formDescriptor += array(
-                       /* Enable this when we can do something useful exporting/importing image information.
-                       'images' => array(
-                               'type' => 'check',
-                               'name' => 'images',
-                               'id' => 'wpExportImages',
-                               'default' => false,
-                       ),*/
                        'wpDownload' => array(
                                'type' => 'check',
                                'name' =>'wpDownload',
@@ -359,11 +350,6 @@ class SpecialExport extends SpecialPage {
                                $pageSet = $this->getPageLinks( $inputPages, $pageSet, $linkDepth );
                        }
 
-                       // Enable this when we can do something useful exporting/importing image information.
-                       // if( $this->images ) ) {
-                       // $pageSet = $this->getImages( $inputPages, $pageSet );
-                       // }
-
                        $pages = array_keys( $pageSet );
 
                        // Normalize titles to the same format and remove dupes, see bug 17374
@@ -549,24 +535,6 @@ class SpecialExport extends SpecialPage {
                return $pageSet;
        }
 
-       /**
-        * Expand a list of pages to include images used in those pages.
-        *
-        * @param array $inputPages List of titles to look up
-        * @param array $pageSet Associative array indexed by titles for output
-        *
-        * @return array Associative array index by titles
-        */
-       private function getImages( $inputPages, $pageSet ) {
-               return $this->getLinks(
-                       $inputPages,
-                       $pageSet,
-                       'imagelinks',
-                       array( 'namespace' => NS_FILE, 'title' => 'il_to' ),
-                       array( 'page_id=il_from' )
-               );
-       }
-
        /**
         * Expand a list of pages to include items used in those pages.
         * @param array $inputPages Array of page titles