GitInfo: Don't try shelling out if it's disabled
[lhc/web/wiklou.git] / includes / Xml.php
index 4f2720e..40be80b 100644 (file)
@@ -124,11 +124,11 @@ class Xml {
         * content you have is already valid xml.
         *
         * @param string $element Element name
-        * @param array $attribs Array of attributes
+        * @param array|null $attribs Array of attributes
         * @param string $contents Content of the element
         * @return string
         */
-       public static function tags( $element, $attribs = null, $contents ) {
+       public static function tags( $element, $attribs, $contents ) {
                return self::openElement( $element, $attribs ) . $contents . "</$element>";
        }
 
@@ -382,7 +382,7 @@ class Xml {
                $value = false, $attribs = []
        ) {
                list( $label, $input ) = self::inputLabelSep( $label, $name, $id, $size, $value, $attribs );
-               return $label . '&#160;' . $input;
+               return $label . "\u{00A0}" . $input;
        }
 
        /**
@@ -420,7 +420,7 @@ class Xml {
        public static function checkLabel( $label, $name, $id, $checked = false, $attribs = [] ) {
                global $wgUseMediaWikiUIEverywhere;
                $chkLabel = self::check( $name, $checked, [ 'id' => $id ] + $attribs ) .
-                       '&#160;' .
+                       "\u{00A0}" .
                        self::label( $label, $id, $attribs );
 
                if ( $wgUseMediaWikiUIEverywhere ) {
@@ -446,7 +446,7 @@ class Xml {
                $checked = false, $attribs = []
        ) {
                return self::radio( $name, $value, $checked, [ 'id' => $id ] + $attribs ) .
-                       '&#160;' .
+                       "\u{00A0}" .
                        self::label( $label, $id, $attribs );
        }