@@ -41,7 +41,7 @@ discard block |
||
41 | 41 | */ |
42 | 42 | public function setType($type = null) |
43 | 43 | { |
44 | - if(null !== $type){ |
|
44 | + if (null !== $type) { |
|
45 | 45 | $this->type = $type; |
46 | 46 | } |
47 | 47 | |
@@ -61,7 +61,7 @@ discard block |
||
61 | 61 | */ |
62 | 62 | public function setText($text = null) |
63 | 63 | { |
64 | - if(null !== $text){ |
|
64 | + if (null !== $text) { |
|
65 | 65 | $this->text = $text; |
66 | 66 | } |
67 | 67 | |
@@ -91,7 +91,7 @@ discard block |
||
91 | 91 | */ |
92 | 92 | public function addAttributes(array $attributes) |
93 | 93 | { |
94 | - foreach($attributes as $key => $value){ |
|
94 | + foreach ($attributes as $key => $value) { |
|
95 | 95 | $this->addAttribute($key, $value); |
96 | 96 | } |
97 | 97 | |
@@ -133,7 +133,7 @@ discard block |
||
133 | 133 | */ |
134 | 134 | public function addChildren(array $children) |
135 | 135 | { |
136 | - foreach($children as $child){ |
|
136 | + foreach ($children as $child) { |
|
137 | 137 | $this->addChild($child); |
138 | 138 | } |
139 | 139 | |
@@ -210,7 +210,7 @@ discard block |
||
210 | 210 | */ |
211 | 211 | private function renderChildren(Markup $root) |
212 | 212 | { |
213 | - foreach($this->children as $child){ |
|
213 | + foreach ($this->children as $child) { |
|
214 | 214 | $child->render($root); |
215 | 215 | } |
216 | 216 | } |
@@ -223,13 +223,13 @@ discard block |
||
223 | 223 | */ |
224 | 224 | private function renderAttributes(Markup $element, array $attributes) |
225 | 225 | { |
226 | - foreach($attributes as $attr => $value){ |
|
227 | - if(is_array($value)){ |
|
226 | + foreach ($attributes as $attr => $value) { |
|
227 | + if (is_array($value)) { |
|
228 | 228 | $glue = 'style' == $attr ? '; ' : ' '; |
229 | 229 | $value = implode($glue, $value); |
230 | 230 | } |
231 | 231 | |
232 | - if(null !== $value){ |
|
232 | + if (null !== $value) { |
|
233 | 233 | $element->set($attr, $value); |
234 | 234 | } |
235 | 235 | } |