PrefixSearch: Remove unnecessary wfSuppressWarnings()
authorBartosz Dziewoński <matma.rex@gmail.com>
Fri, 11 Apr 2014 21:42:45 +0000 (23:42 +0200)
committerBartosz Dziewoński <matma.rex@gmail.com>
Fri, 11 Apr 2014 21:42:45 +0000 (23:42 +0200)
It was added in 4492854f (r68563), where the code this was suppressing
warnings for was something rather different. It doesn't seem necessary now.

Change-Id: Ia501afd1244b94563fe52294945798963f8db1a9

includes/PrefixSearch.php

index 957a119..45c591a 100644 (file)
@@ -192,13 +192,11 @@ abstract class PrefixSearch {
                $srchres = array();
                foreach ( $keys as $pageKey => $page ) {
                        if ( $searchKey === '' || strpos( $pageKey, $searchKey ) === 0 ) {
-                               wfSuppressWarnings();
                                // bug 27671: Don't use SpecialPage::getTitleFor() here because it
                                // localizes its input leading to searches for e.g. Special:All
                                // returning Spezial:MediaWiki-Systemnachrichten and returning
                                // Spezial:Alle_Seiten twice when $wgLanguageCode == 'de'
                                $srchres[] = Title::makeTitleSafe( NS_SPECIAL, $page );
-                               wfRestoreWarnings();
                        }
 
                        if ( count( $srchres ) >= $limit ) {