Completed
Push — 1.x ( 4583b7...7c9630 )
by Asao
01:32
created
src/Tags/ElementTrait.php 1 patch
Doc Comments   +6 added lines patch added patch discarded remove patch
@@ -13,8 +13,14 @@
 block discarded – undo
13 13
      */
14 14
     private $label;
15 15
 
16
+    /**
17
+     * @param string $name
18
+     */
16 19
     abstract public function get($name);
17 20
 
21
+    /**
22
+     * @param string $key
23
+     */
18 24
     abstract public function setAttribute($key, $value = true, $sep = false);
19 25
 
20 26
     /**
Please login to merge, or discard this patch.
src/Data/AbstractData.php 1 patch
Spacing   +2 added lines, -2 removed lines patch added patch discarded remove patch
@@ -91,7 +91,7 @@  discard block
 block discarded – undo
91 91
             if (is_array($found)) {
92 92
                 return in_array($value, $found);
93 93
             }
94
-            return (string)$value === (string)$found;
94
+            return (string) $value === (string) $found;
95 95
         }
96 96
         return true;
97 97
     }
@@ -149,7 +149,7 @@  discard block
 block discarded – undo
149 149
                 ? true
150 150
                 : (string) $inputs;
151 151
         }
152
-        foreach($levels as $key => $next) {
152
+        foreach ($levels as $key => $next) {
153 153
             if (Accessor::has($inputs, $key)) {
154 154
                 return $this->recurseGet($next, Accessor::get($inputs, $key));
155 155
             }
Please login to merge, or discard this patch.
src/Tags/TagToString.php 2 patches
Spacing   +3 added lines, -3 removed lines patch added patch discarded remove patch
@@ -12,9 +12,9 @@  discard block
 block discarded – undo
12 12
         $prop = (string) $element->getAttribute();
13 13
         $tag  = $element->getTagName();
14 14
         if ($element->isClosed() || $element->hasContents()) {
15
-            $html = '<' . $tag . $prop . ' >' . $element->getContents() . "</{$tag}>" . "\n";
15
+            $html = '<'.$tag.$prop.' >'.$element->getContents()."</{$tag}>"."\n";
16 16
         } else {
17
-            $html = '<' . $tag . $prop . ' >' . "\n";
17
+            $html = '<'.$tag.$prop.' >'."\n";
18 18
         }
19 19
         $html = rtrim($html);
20 20
         return $html;
@@ -38,7 +38,7 @@  discard block
 block discarded – undo
38 38
                 }
39 39
                 $property[] = "{$key}=\"{$val}\"";
40 40
             }
41
-            return ' ' . implode(' ', $property);
41
+            return ' '.implode(' ', $property);
42 42
         }
43 43
         return '';
44 44
     }
Please login to merge, or discard this patch.
Braces   +6 added lines, -2 removed lines patch added patch discarded remove patch
@@ -29,8 +29,12 @@
 block discarded – undo
29 29
         if ($attributes = $element->getAttribute()) {
30 30
             $property = [];
31 31
             foreach ($attributes as $key => $val) {
32
-                if ($val === false) continue;
33
-                if ($key === 'value' && '' === (string) $val) continue;
32
+                if ($val === false) {
33
+                    continue;
34
+                }
35
+                if ($key === 'value' && '' === (string) $val) {
36
+                    continue;
37
+                }
34 38
                 if (is_numeric($key)) {
35 39
                     $key = $val;
36 40
                 } elseif ($val === true) {
Please login to merge, or discard this patch.