Merge "Add autocomplete for WhatLinksHere subpages"
[lhc/web/wiklou.git] / includes / search / SearchHighlighter.php
index c3c3a8f..255d005 100644 (file)
@@ -67,7 +67,6 @@ class SearchHighlighter {
                $spat .= '/';
                $textExt = array(); // text extracts
                $otherExt = array(); // other extracts
-               wfProfileIn( "$fname-split" );
                $start = 0;
                $textLen = strlen( $text );
                $count = 0; // sequence number to maintain ordering
@@ -132,8 +131,6 @@ class SearchHighlighter {
 
                $all = $textExt + $otherExt; // these have disjunct key sets
 
-               wfProfileOut( "$fname-split" );
-
                // prepare regexps
                foreach ( $terms as $index => $term ) {
                        // manually do upper/lowercase stuff for utf-8 since PHP won't do it
@@ -163,8 +160,6 @@ class SearchHighlighter {
                $pat1 = "/(" . $phrase . ")/ui";
                $pat2 = "/$patPre(" . $anyterm . ")$patPost/ui";
 
-               wfProfileIn( "$fname-extract" );
-
                $left = $contextlines;
 
                $snippets = array();
@@ -287,8 +282,6 @@ class SearchHighlighter {
                        }
                }
 
-               wfProfileOut( "$fname-extract" );
-
                return $extract;
        }
 
@@ -452,7 +445,6 @@ class SearchHighlighter {
         */
        function removeWiki( $text ) {
                $fname = __METHOD__;
-               wfProfileIn( $fname );
 
                // $text = preg_replace( "/'{2,5}/", "", $text );
                // $text = preg_replace( "/\[[a-z]+:\/\/[^ ]+ ([^]]+)\]/", "\\2", $text );
@@ -474,7 +466,6 @@ class SearchHighlighter {
                $text = preg_replace( "/('''|<\/?[iIuUbB]>)/", "", $text );
                $text = preg_replace( "/''/", "", $text );
 
-               wfProfileOut( $fname );
                return $text;
        }
 
@@ -523,7 +514,6 @@ class SearchHighlighter {
                $lineno = 0;
 
                $extract = "";
-               wfProfileIn( "$fname-extract" );
                foreach ( $lines as $line ) {
                        if ( 0 == $contextlines ) {
                                break;
@@ -551,7 +541,6 @@ class SearchHighlighter {
 
                        $extract .= "${line}\n";
                }
-               wfProfileOut( "$fname-extract" );
 
                return $extract;
        }