Passed
Pull Request — master (#187)
by Nicolas
06:21
created
src/AccordionBuilder.php 1 patch
Indentation   +1 added lines, -1 removed lines patch added patch discarded remove patch
@@ -6,7 +6,7 @@
 block discarded – undo
6 6
 {
7 7
     public function __construct($name, $type = 'accordion', $config = [])
8 8
     {
9
-       parent::__construct($name, $type, $config);
9
+        parent::__construct($name, $type, $config);
10 10
     }
11 11
 
12 12
     public function setOpen($value = 1)
Please login to merge, or discard this patch.
src/Transform/RecursiveTransform.php 1 patch
Spacing   +1 added lines, -1 removed lines patch added patch discarded remove patch
@@ -31,7 +31,7 @@
 block discarded – undo
31 31
      */
32 32
     public function transform($config)
33 33
     {
34
-        foreach ($config as $key => $value ) {
34
+        foreach ($config as $key => $value) {
35 35
             if ($this->shouldTransformValue($key, $config)) {
36 36
                 $config = $this->transformConfig($config);
37 37
                 $config[$key] = $this->transformValue($value);
Please login to merge, or discard this patch.
src/RepeaterBuilder.php 1 patch
Spacing   +2 added lines, -2 removed lines patch added patch discarded remove patch
@@ -45,7 +45,7 @@  discard block
 block discarded – undo
45 45
                 $config['_has_custom_collapsed_key'] = true;
46 46
             } else {
47 47
                 $fieldKey = preg_replace('/^field_/', '', $fieldKey);
48
-                $config['collapsed'] = $this->getName() . '_' . $fieldKey;
48
+                $config['collapsed'] = $this->getName().'_'.$fieldKey;
49 49
             }
50 50
         }
51 51
         return $config;
@@ -74,6 +74,6 @@  discard block
 block discarded – undo
74 74
      */
75 75
     private function getDefaultButtonLabel()
76 76
     {
77
-        return 'Add ' . $this->singularize($this->getLabel());
77
+        return 'Add '.$this->singularize($this->getLabel());
78 78
     }
79 79
 }
Please login to merge, or discard this patch.
src/Transform/ConditionalField.php 2 patches
Indentation   +1 added lines, -1 removed lines patch added patch discarded remove patch
@@ -34,7 +34,7 @@
 block discarded – undo
34 34
             return $this->getBuilder()->getField($value)->getKey();
35 35
         }
36 36
 
37
-       return $value;
37
+        return $value;
38 38
     }
39 39
 
40 40
     public function transformConfig($config)
Please login to merge, or discard this patch.
Spacing   +1 added lines, -1 removed lines patch added patch discarded remove patch
@@ -30,7 +30,7 @@
 block discarded – undo
30 30
 
31 31
     public function transformValue($value)
32 32
     {
33
-        if ($this->getBuilder()->fieldExists($value)){
33
+        if ($this->getBuilder()->fieldExists($value)) {
34 34
             return $this->getBuilder()->getField($value)->getKey();
35 35
         }
36 36
 
Please login to merge, or discard this patch.
src/FlexibleContentBuilder.php 2 patches
Spacing   +2 added lines, -2 removed lines patch added patch discarded remove patch
@@ -47,7 +47,7 @@  discard block
 block discarded – undo
47 47
      */
48 48
     private function buildLayouts()
49 49
     {
50
-        return array_map(function ($layout) {
50
+        return array_map(function($layout) {
51 51
             $layout = ($layout instanceof Builder) ? $layout->build() : $layout;
52 52
             return $this->transformLayout($layout);
53 53
         }, $this->getLayouts());
@@ -175,7 +175,7 @@  discard block
 block discarded – undo
175 175
      */
176 176
     private function getDefaultButtonLabel()
177 177
     {
178
-        return 'Add ' . $this->singularize($this->getLabel());
178
+        return 'Add '.$this->singularize($this->getLabel());
179 179
     }
180 180
 
181 181
     public function removeLayout($name)
Please login to merge, or discard this patch.
Braces   +1 added lines, -2 removed lines patch added patch discarded remove patch
@@ -223,8 +223,7 @@
 block discarded – undo
223 223
             } elseif ($modify instanceof \Closure) {
224 224
                 throw new \Exception('FieldsBuilder can\'t be modified with a closure.');
225 225
             }
226
-        }
227
-        else if (is_array($modify)) {
226
+        } else if (is_array($modify)) {
228 227
             $this->updateConfig($modify);
229 228
         } elseif ($modify instanceof \Closure) {
230 229
             throw new \Exception('FlexibleContentBuilder can\'t be modified with a closure.');
Please login to merge, or discard this patch.
src/FieldsBuilder.php 1 patch
Spacing   +3 added lines, -3 removed lines patch added patch discarded remove patch
@@ -99,7 +99,7 @@  discard block
 block discarded – undo
99 99
     private function namespaceGroupKey($key)
100 100
     {
101 101
         if (strpos($key, 'group_') !== 0) {
102
-            $key = 'group_' . $key;
102
+            $key = 'group_'.$key;
103 103
         }
104 104
         return $key;
105 105
     }
@@ -124,7 +124,7 @@  discard block
 block discarded – undo
124 124
      */
125 125
     private function buildFields()
126 126
     {
127
-        $fields = array_map(function ($field) {
127
+        $fields = array_map(function($field) {
128 128
             return ($field instanceof Builder) ? $field->build() : $field;
129 129
         }, $this->getFields());
130 130
 
@@ -558,7 +558,7 @@  discard block
 block discarded – undo
558 558
      */
559 559
     public function addMessage($label, $message, array $args = [])
560 560
     {
561
-        $name = $this->generateName($label) . '_message';
561
+        $name = $this->generateName($label).'_message';
562 562
         $args = array_merge([
563 563
             'label' => $label,
564 564
             'message' => $message,
Please login to merge, or discard this patch.
src/Transform/NamespaceFieldKey.php 1 patch
Spacing   +2 added lines, -2 removed lines patch added patch discarded remove patch
@@ -49,9 +49,9 @@
 block discarded – undo
49 49
         if ($groupName) {
50 50
             // remove field_ or group_ if already at the begining of the key
51 51
             $value = preg_replace('/^field_|^group_/', '', $value);
52
-            $namespace .= str_replace(' ', '_', $groupName) . '_';
52
+            $namespace .= str_replace(' ', '_', $groupName).'_';
53 53
         }
54
-        return strtolower($namespace . $value);
54
+        return strtolower($namespace.$value);
55 55
     }
56 56
 
57 57
     public function shouldTransformValue($key, $config)
Please login to merge, or discard this patch.
src/FieldBuilder.php 1 patch
Spacing   +1 added lines, -1 removed lines patch added patch discarded remove patch
@@ -140,7 +140,7 @@
 block discarded – undo
140 140
     public function setKey($key)
141 141
     {
142 142
         if (!preg_match('/^field_/', $key)) {
143
-            $key = 'field_' . $key;
143
+            $key = 'field_'.$key;
144 144
         }
145 145
 
146 146
         return $this->setConfig('key', $key);
Please login to merge, or discard this patch.