Merge "Allow tests to run with a non-writable source tree"
[lhc/web/wiklou.git] / includes / Linker.php
index 08a5724..0aa8ec5 100644 (file)
@@ -431,7 +431,11 @@ class Linker {
                        $s = $thumb->toHtml( $params );
                }
                if ( $frameParams['align'] != '' ) {
-                       $s = "<div class=\"float{$frameParams['align']}\">{$s}</div>";
+                       $s = Html::rawElement(
+                               'div',
+                               [ 'class' => 'float' . $frameParams['align'] ],
+                               $s
+                       );
                }
                return str_replace( "\n", ' ', $prefix . $s . $postfix );
        }
@@ -1208,7 +1212,8 @@ class Linker {
         * @param string|null $wikiId Id of the wiki to link to (if not the local wiki),
         *  as used by WikiMap.
         *
-        * @return string
+        * @return string HTML
+        * @return-taint escapes_html
         */
        public static function formatLinksInComment(
                $comment, $title = null, $local = false, $wikiId = null