Follow-up r79655: array_diff makes in_array unnecessary
authorBryan Tong Minh <btongminh@users.mediawiki.org>
Wed, 5 Jan 2011 19:58:09 +0000 (19:58 +0000)
committerBryan Tong Minh <btongminh@users.mediawiki.org>
Wed, 5 Jan 2011 19:58:09 +0000 (19:58 +0000)
includes/Title.php

index 9bb7137..ca4c35e 100644 (file)
@@ -4119,7 +4119,7 @@ class Title {
                
                $types = $this->exists() ? $wgRestrictionTypes : array( 'create' );
 
-               if ( $this->getNamespace() != NS_FILE && in_array( 'upload', $types ) ) {
+               if ( $this->getNamespace() != NS_FILE ) {
                        $types = array_diff( $types, array( 'upload' ) );
                }