From 1ad788ee03e07161009daad363a6f61ae15b19d1 Mon Sep 17 00:00:00 2001 From: jeroendedauw Date: Mon, 7 Sep 2015 21:21:24 +0200 Subject: [PATCH] Remove commented out code in SpecialExport The removed code was about exporting/importing image information, which is not possible at the moment, but also nobody seems to work on this. Change-Id: Ie10d3bc23454ca797f41bd12c4e05360233978a2 --- includes/specials/SpecialExport.php | 32 ----------------------------- 1 file changed, 32 deletions(-) diff --git a/includes/specials/SpecialExport.php b/includes/specials/SpecialExport.php index 69b795d9e4..39c4d77111 100644 --- a/includes/specials/SpecialExport.php +++ b/includes/specials/SpecialExport.php @@ -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 -- 2.20.1