Passed
Push — main ( f0e9e1...b967d0 )
by Sammy
07:14
created
src/Element.php 2 patches
Spacing   +2 added lines, -2 removed lines patch added patch discarded remove patch
@@ -309,7 +309,7 @@  discard block
 block discarded – undo
309 309
         // second argument, an array for HTML attributes
310 310
         $attributes = $arguments[1] ?? [];
311 311
 
312
-        if(is_string($content))
312
+        if (is_string($content))
313 313
             return new Element($tag, $content, $attributes);
314 314
 
315 315
         throw new InvalidArgumentException('missing content or content not a string');
@@ -356,7 +356,7 @@  discard block
 block discarded – undo
356 356
         $ret = '';
357 357
         foreach ($attributes as $k => $v) {
358 358
             if (self::isValidValue($v)) {
359
-                $ret .=  ' ' . (self::isBooleanAttribute($k) ? $v : sprintf(self::FORMAT_ATTRIBUTES, $k, $v));
359
+                $ret .= ' '.(self::isBooleanAttribute($k) ? $v : sprintf(self::FORMAT_ATTRIBUTES, $k, $v));
360 360
             }
361 361
         }
362 362
 
Please login to merge, or discard this patch.
Braces   +3 added lines, -2 removed lines patch added patch discarded remove patch
@@ -309,8 +309,9 @@
 block discarded – undo
309 309
         // second argument, an array for HTML attributes
310 310
         $attributes = $arguments[1] ?? [];
311 311
 
312
-        if(is_string($content))
313
-            return new Element($tag, $content, $attributes);
312
+        if(is_string($content)) {
313
+                    return new Element($tag, $content, $attributes);
314
+        }
314 315
 
315 316
         throw new InvalidArgumentException('missing content or content not a string');
316 317
     }
Please login to merge, or discard this patch.
src/Form.php 1 patch
Spacing   +4 added lines, -4 removed lines patch added patch discarded remove patch
@@ -108,7 +108,7 @@  discard block
 block discarded – undo
108 108
         foreach ($list as $value => $label) {
109 109
             $option_attributes = ['value' => $value];
110 110
             if ($selected == $value) {
111
-                $option_attributes['selected'] =  'selected';
111
+                $option_attributes['selected'] = 'selected';
112 112
             }
113 113
 
114 114
             $options .= new Element('option', "$label", $option_attributes);
@@ -126,7 +126,7 @@  discard block
 block discarded – undo
126 126
      */
127 127
     public static function legend(string $label, array $attributes = []): string
128 128
     {
129
-        return '' . (new Element('legend', $label, $attributes));
129
+        return ''.(new Element('legend', $label, $attributes));
130 130
     }
131 131
 
132 132
     /**
@@ -147,7 +147,7 @@  discard block
 block discarded – undo
147 147
 
148 148
     public static function button(string $label, array $attributes = []): string
149 149
     {
150
-        return  '' . (new Element('button', $label, $attributes));
150
+        return  ''.(new Element('button', $label, $attributes));
151 151
     }
152 152
 
153 153
     /**
@@ -201,6 +201,6 @@  discard block
 block discarded – undo
201 201
             unset($attributes['label']);
202 202
         }
203 203
 
204
-        return $label . (new Element($tag, $content, $attributes));
204
+        return $label.(new Element($tag, $content, $attributes));
205 205
     }
206 206
 }
Please login to merge, or discard this patch.