Merge "Tweaked the message for non-MW exceptions"
[lhc/web/wiklou.git] / includes / Sanitizer.php
index 11c30a2..6942ac0 100644 (file)
@@ -372,8 +372,6 @@ class Sanitizer {
                static $htmlpairsStatic, $htmlsingle, $htmlsingleonly, $htmlnest, $tabletags,
                        $htmllist, $listtags, $htmlsingleallowed, $htmlelementsStatic, $staticInitialised;
 
-               wfProfileIn( __METHOD__ );
-
                // Base our staticInitialised variable off of the global config state so that if the globals
                // are changed (like in the screwed up test system) we will re-initialise the settings.
                $globalContext = implode( '-', compact( 'wgAllowMicrodataAttributes', 'wgAllowImageTag' ) );
@@ -600,7 +598,6 @@ class Sanitizer {
                                $text .= '<' . str_replace( '>', '>', $x );
                        }
                }
-               wfProfileOut( __METHOD__ );
                return $text;
        }
 
@@ -615,7 +612,6 @@ class Sanitizer {
         * @return string
         */
        static function removeHTMLcomments( $text ) {
-               wfProfileIn( __METHOD__ );
                while ( ( $start = strpos( $text, '<!--' ) ) !== false ) {
                        $end = strpos( $text, '-->', $start + 4 );
                        if ( $end === false ) {
@@ -646,7 +642,6 @@ class Sanitizer {
                                $text = substr_replace( $text, '', $start, $end - $start );
                        }
                }
-               wfProfileOut( __METHOD__ );
                return $text;
        }
 
@@ -1267,24 +1262,6 @@ class Sanitizer {
                }
        }
 
-       /**
-        * Normalize whitespace and character references in an XML source-
-        * encoded text for an attribute value.
-        *
-        * See http://www.w3.org/TR/REC-xml/#AVNormalize for background,
-        * but note that we're not returning the value, but are returning
-        * XML source fragments that will be slapped into output.
-        *
-        * @param string $text
-        * @return string
-        * @todo Remove, unused?
-        */
-       private static function normalizeAttributeValue( $text ) {
-               return str_replace( '"', '&quot;',
-                       self::normalizeWhitespace(
-                               Sanitizer::normalizeCharReferences( $text ) ) );
-       }
-
        /**
         * @param string $text
         * @return string