Merge "Add tests for LanguageConverter classes that didn't have them"
[lhc/web/wiklou.git] / includes / specials / SpecialRecentchangeslinked.php
index e947586..dc210db 100644 (file)
@@ -55,7 +55,7 @@ class SpecialRecentChangesLinked extends SpecialRecentChanges {
                        return false;
                }
                $outputPage = $this->getOutput();
-               $title = Title::newFromURL( $target );
+               $title = Title::newFromText( $target );
                if ( !$title || $title->isExternal() ) {
                        $outputPage->addHtml( '<div class="errorbox">' . $this->msg( 'allpagesbadtitle' )
                                        ->parse() . '</div>' );
@@ -273,12 +273,6 @@ class SpecialRecentChangesLinked extends SpecialRecentChanges {
         * @return string[] Matching subpages
         */
        public function prefixSearchSubpages( $search, $limit, $offset ) {
-               if ( $search === '' ) {
-                       return array();
-               }
-               // Autocomplete subpage the same as a normal search
-               $prefixSearcher = new StringPrefixSearch;
-               $result = $prefixSearcher->search( $search, $limit, array(), $offset );
-               return $result;
+               return $this->prefixSearchString( $search, $limit, $offset );
        }
 }