From f1ff44d518a5ea6c0c63af6254e292e4d49395b2 Mon Sep 17 00:00:00 2001 From: "Mark A. Hershberger" Date: Thu, 27 Oct 2011 17:58:30 +0000 Subject: [PATCH] Fixes Bug #28277 by allowing redirects on the stream reader. Fixes a regression where pages specifying a w:en:Sprint would result in a url like http://pt.wikipedia.org/wiki/en:Special:Export/Sprint which, at least in 1.16, would mean the reader follow the redirect to http://en.wikipedia.org/wiki/Special:Export/Sprint. --- includes/Import.php | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/includes/Import.php b/includes/Import.php index 502b015b13..dfbd522f03 100644 --- a/includes/Import.php +++ b/includes/Import.php @@ -1518,7 +1518,7 @@ class ImportStreamSource { # quicker and sorts out user-agent problems which might # otherwise prevent importing from large sites, such # as the Wikimedia cluster, etc. - $data = Http::request( $method, $url ); + $data = Http::request( $method, $url, array( 'followRedirects' => true ) ); if( $data !== false ) { $file = tmpfile(); fwrite( $file, $data ); -- 2.20.1