Merge "rdbms: set the schema in the LBFactory local domain"
[lhc/web/wiklou.git] / includes / parser / Sanitizer.php
index 8fee2c7..de7a6fa 100644 (file)
@@ -1171,7 +1171,9 @@ class Sanitizer {
                # Stupid hack
                $encValue = preg_replace_callback(
                        '/((?i)' . wfUrlProtocols() . ')/',
-                       [ self::class, 'armorLinksCallback' ],
+                       function ( $matches ) {
+                               return str_replace( ':', ':', $matches[1] );
+                       },
                        $encValue );
                return $encValue;
        }
@@ -1416,15 +1418,6 @@ class Sanitizer {
                return $html;
        }
 
-       /**
-        * Regex replace callback for armoring links against further processing.
-        * @param array $matches
-        * @return string
-        */
-       private static function armorLinksCallback( $matches ) {
-               return str_replace( ':', ':', $matches[1] );
-       }
-
        /**
         * Return an associative array of attribute names and values from
         * a partial tag string. Attribute names are forced to lowercase,