Revert "Replace Media namespace redirects with File namespace"
authorKrinkle <krinklemail@gmail.com>
Tue, 9 Oct 2018 01:19:02 +0000 (01:19 +0000)
committerKrinkle <krinklemail@gmail.com>
Tue, 9 Oct 2018 01:19:12 +0000 (01:19 +0000)
Per T203942.

This reverts commit 613e269920a7d268b012d61fec24fc4d04b1cd7a.

Change-Id: I4febbe9c650894976a580e584d0a7c11de12ff37

includes/MediaWiki.php

index e10a530..4636ba3 100644 (file)
@@ -369,11 +369,6 @@ class MediaWiki {
                        }
                        throw new HttpError( 500, $message );
                }
-               // Protect against redirects to NS_MEDIA namespace
-               // when the user probably wants NS_FILE
-               if ( $title->inNamespace( NS_MEDIA ) ) {
-                       $title->mNamespace = NS_FILE;
-               }
                $output->setCdnMaxage( 1200 );
                $output->redirect( $targetUrl, '301' );
                return true;