Passed
Push — master ( 765134...0db1d4 )
by Guillaume
02:13
created
src/Checker/MysqlDatabaseCheckerService.php 1 patch
Spacing   +1 added lines, -1 removed lines patch added patch discarded remove patch
@@ -188,7 +188,7 @@
 block discarded – undo
188 188
     {
189 189
         $statements = [];
190 190
         foreach ($modificationsBetweenTable as $modifications) {
191
-            foreach ((array)$modifications as $modification) {
191
+            foreach ((array) $modifications as $modification) {
192 192
                 $statements[] = $modification;
193 193
             }
194 194
         }
Please login to merge, or discard this patch.
src/Factory/JsonDatabaseFactory.php 1 patch
Spacing   +6 added lines, -6 removed lines patch added patch discarded remove patch
@@ -54,7 +54,7 @@  discard block
 block discarded – undo
54 54
             if (isset($row['collate'])) {
55 55
                 $table->setCollate($dataTable['collate']);
56 56
             }
57
-            foreach ((array)$dataTable['columns'] as $columnName => $row) {
57
+            foreach ((array) $dataTable['columns'] as $columnName => $row) {
58 58
                 $column = new MysqlDatabaseColumn($columnName, $row['type'], $row['length'], $row['nullable'], $row['defaultValue'], $row['extra']);
59 59
                 if (isset($row['collate'])) {
60 60
                     $column->setCollate($row['collate']);
@@ -62,13 +62,13 @@  discard block
 block discarded – undo
62 62
                 $table->addColumn($column);
63 63
 
64 64
             }
65
-            foreach ((array)$dataTable['indexes'] as $row) {
65
+            foreach ((array) $dataTable['indexes'] as $row) {
66 66
                 $table->addIndex($row['columns'], $row['name']);
67 67
             }
68 68
             if (isset($dataTable['primary'])) {
69
-                $table->addPrimary((array)$dataTable['primary']);
69
+                $table->addPrimary((array) $dataTable['primary']);
70 70
             }
71
-            foreach ((array)$dataTable['uniques'] as $row) {
71
+            foreach ((array) $dataTable['uniques'] as $row) {
72 72
                 $table->addUnique($row['columns'], $row['name']);
73 73
             }
74 74
             $tables[] = $table;
@@ -128,11 +128,11 @@  discard block
 block discarded – undo
128 128
         $export = [];
129 129
         foreach ($data as $nomTable => $table) {
130 130
             $dataTable = $resolverTable->resolve($table);
131
-            foreach ((array)$dataTable['columns'] as $columnName => $column) {
131
+            foreach ((array) $dataTable['columns'] as $columnName => $column) {
132 132
                 $dataTable['columns'][$columnName] = $resolverColumns->resolve($column);
133 133
             }
134 134
             foreach (['indexes', 'uniques'] as $indexKey) {
135
-                foreach ((array)$dataTable[$indexKey] as $keyIndex => $index) {
135
+                foreach ((array) $dataTable[$indexKey] as $keyIndex => $index) {
136 136
                     $dataTable[$indexKey][$keyIndex] = $resolverIndex->resolve($index);
137 137
                 }
138 138
             }
Please login to merge, or discard this patch.
src/Structure/MysqlDatabaseTable.php 1 patch
Spacing   +2 added lines, -2 removed lines patch added patch discarded remove patch
@@ -194,7 +194,7 @@  discard block
 block discarded – undo
194 194
     {
195 195
         $statements = [];
196 196
         foreach ($modificationsBetweenTable as $modifications) {
197
-            foreach ((array)$modifications as $modification) {
197
+            foreach ((array) $modifications as $modification) {
198 198
                 $statements[] = $modification;
199 199
             }
200 200
         }
@@ -209,7 +209,7 @@  discard block
 block discarded – undo
209 209
         }
210 210
         $tmp = [];
211 211
         foreach ($modifications as $modification) {
212
-            $tmp[] = trim(str_replace(['ALTER TABLE `' . $this->getTable() . '` ADD COLUMN', 'ALTER TABLE `' . $this->getTable() . '` ADD ', ';',], '', $modification));
212
+            $tmp[] = trim(str_replace(['ALTER TABLE `' . $this->getTable() . '` ADD COLUMN', 'ALTER TABLE `' . $this->getTable() . '` ADD ', ';', ], '', $modification));
213 213
         }
214 214
         $collate = $this->getCollate() == '' ? '' : sprintf("COLLATE='%s'", $this->getCollate());
215 215
 
Please login to merge, or discard this patch.
src/Structure/MysqlDatabaseColumn.php 1 patch
Spacing   +3 added lines, -3 removed lines patch added patch discarded remove patch
@@ -74,7 +74,7 @@  discard block
 block discarded – undo
74 74
     {
75 75
         $isEnum = explode('enum', $this->type);
76 76
         if (!empty($isEnum)) {
77
-            $numberElements = substr_count(str_replace(['(', ')', "'",], '', $isEnum[1]), ',') + 1;
77
+            $numberElements = substr_count(str_replace(['(', ')', "'", ], '', $isEnum[1]), ',') + 1;
78 78
             if ($numberElements == 2) {
79 79
                 $this->type = 'tinyint';
80 80
                 $this->length = 1;
@@ -106,7 +106,7 @@  discard block
 block discarded – undo
106 106
         $collate = $this->getCollate() == '' ? '' : sprintf("COLLATE '%s'", $this->getCollate());
107 107
         $modification = sprintf('ALTER TABLE `%s` ADD COLUMN `%s` %s %s NULL %s %s %s;', $this->getTable(), $this->getName(), $this->getColonneType(), $null, $default, $this->getExtra(), $collate);
108 108
 
109
-        return [str_replace(['   ', '  ',], ' ', $modification)];
109
+        return [str_replace(['   ', '  ', ], ' ', $modification)];
110 110
     }
111 111
 
112 112
     /**
@@ -180,6 +180,6 @@  discard block
 block discarded – undo
180 180
         $collate = $this->getCollate() == '' ? '' : sprintf("COLLATE '%s'", $this->getCollate());
181 181
         $modification = sprintf('ALTER TABLE `%s` CHANGE COLUMN %s %s %s %s NULL %s %s %s;', $this->getTable(), $columnName, $columnName, $this->getColonneType(), $null, $default, $this->getExtra(), $collate);
182 182
 
183
-        return [str_replace(['   ', '  ',], ' ', $modification)];
183
+        return [str_replace(['   ', '  ', ], ' ', $modification)];
184 184
     }
185 185
 }
Please login to merge, or discard this patch.
src/LoggerTrait.php 1 patch
Spacing   +1 added lines, -1 removed lines patch added patch discarded remove patch
@@ -18,7 +18,7 @@
 block discarded – undo
18 18
 
19 19
     public function log($level, $message, array $context = [])
20 20
     {
21
-        if($this->logger){
21
+        if ($this->logger) {
22 22
             $this->logger->log($level, $message, $context);
23 23
         }
24 24
     }
Please login to merge, or discard this patch.