Completed
Push — master ( 81e965...45c7cd )
by David
26s queued 13s
created
src/Schema/ForeignKey.php 1 patch
Spacing   +1 added lines, -1 removed lines patch added patch discarded remove patch
@@ -63,7 +63,7 @@
 block discarded – undo
63 63
     public function getCacheKey(): string
64 64
     {
65 65
         if ($this->cacheKey === null) {
66
-            $this->cacheKey = 'from__' . implode(',', $this->getUnquotedLocalColumns()) . '__to__table__' . $this->getForeignTableName() . '__columns__' . implode(',', $this->getUnquotedForeignColumns());
66
+            $this->cacheKey = 'from__'.implode(',', $this->getUnquotedLocalColumns()).'__to__table__'.$this->getForeignTableName().'__columns__'.implode(',', $this->getUnquotedForeignColumns());
67 67
         }
68 68
         return $this->cacheKey;
69 69
     }
Please login to merge, or discard this patch.
src/Utils/TDBMDaoGenerator.php 1 patch
Spacing   +14 added lines, -14 removed lines patch added patch discarded remove patch
@@ -88,11 +88,11 @@  discard block
 block discarded – undo
88 88
 
89 89
         // Remove all beans and daos from junction tables
90 90
         $junctionTables = $this->configuration->getSchemaAnalyzer()->detectJunctionTables(true);
91
-        $junctionTableNames = array_map(function (Table $table) {
91
+        $junctionTableNames = array_map(function(Table $table) {
92 92
             return $table->getName();
93 93
         }, $junctionTables);
94 94
 
95
-        $tableList = array_filter($tableList, function (Table $table) use ($junctionTableNames) {
95
+        $tableList = array_filter($tableList, function(Table $table) use ($junctionTableNames) {
96 96
             return !in_array($table->getName(), $junctionTableNames, true);
97 97
         });
98 98
 
@@ -170,7 +170,7 @@  discard block
 block discarded – undo
170 170
         $fileContent = $this->psr2Fix($fileContent);
171 171
         // Add the declare strict-types directive
172 172
         $commentEnd = strpos($fileContent, ' */') + 3;
173
-        $fileContent = substr($fileContent, 0, $commentEnd) . "\n\ndeclare(strict_types=1);" . substr($fileContent, $commentEnd + 1);
173
+        $fileContent = substr($fileContent, 0, $commentEnd)."\n\ndeclare(strict_types=1);".substr($fileContent, $commentEnd + 1);
174 174
 
175 175
         $this->dumpFile($possibleBaseFileName, $fileContent);
176 176
 
@@ -232,7 +232,7 @@  discard block
 block discarded – undo
232 232
         $fileContent = $this->psr2Fix($fileContent);
233 233
         // Add the declare strict-types directive
234 234
         $commentEnd = strpos($fileContent, ' */') + 3;
235
-        $fileContent = substr($fileContent, 0, $commentEnd) . "\n\ndeclare(strict_types=1);" . substr($fileContent, $commentEnd + 1);
235
+        $fileContent = substr($fileContent, 0, $commentEnd)."\n\ndeclare(strict_types=1);".substr($fileContent, $commentEnd + 1);
236 236
 
237 237
         $this->dumpFile($possibleBaseFileName, $fileContent);
238 238
 
@@ -290,7 +290,7 @@  discard block
 block discarded – undo
290 290
         $resultIteratorClassName = $beanDescriptor->getResultIteratorClassName();
291 291
         $resultIteratorBaseClassName = $beanDescriptor->getBaseResultIteratorClassName();
292 292
         $resultIteratorNamespace = $this->configuration->getResultIteratorNamespace();
293
-        $resultIteratorBaseNamespace = $resultIteratorNamespace . '\\Generated';
293
+        $resultIteratorBaseNamespace = $resultIteratorNamespace.'\\Generated';
294 294
         $beanClassWithoutNameSpace = $beanDescriptor->getBeanClassName();
295 295
         $file = $beanDescriptor->generateResultIteratorPhpCode();
296 296
         if ($file === null) {
@@ -299,7 +299,7 @@  discard block
 block discarded – undo
299 299
 
300 300
         $fileContent = $this->psr2Fix($file->generate());
301 301
         $commentEnd = strpos($fileContent, ' */') + 3;
302
-        $fileContent = substr($fileContent, 0, $commentEnd) . "\n\ndeclare(strict_types=1);" . substr($fileContent, $commentEnd + 1);
302
+        $fileContent = substr($fileContent, 0, $commentEnd)."\n\ndeclare(strict_types=1);".substr($fileContent, $commentEnd + 1);
303 303
 
304 304
         $baseResultIteratorFilePath = $this->configuration->getPathFinder()->getPath($resultIteratorBaseNamespace.'\\'.$resultIteratorBaseClassName)->getPathname();
305 305
         $this->dumpFile($baseResultIteratorFilePath, $fileContent);
@@ -364,7 +364,7 @@  discard block
 block discarded – undo
364 364
 
365 365
         $constructorMethod = new MethodGenerator(
366 366
             '__construct',
367
-            [ new ParameterGenerator('container', ContainerInterface::class) ],
367
+            [new ParameterGenerator('container', ContainerInterface::class)],
368 368
             MethodGenerator::FLAG_PUBLIC,
369 369
             '$this->container = $container;'
370 370
         );
@@ -380,7 +380,7 @@  discard block
 block discarded – undo
380 380
 
381 381
             $daoInstanceProperty = new PropertyGenerator($daoInstanceName);
382 382
             $daoInstanceProperty->setVisibility(AbstractMemberGenerator::VISIBILITY_PRIVATE);
383
-            $daoInstanceProperty->setDocBlock(new DocBlockGenerator(null, null, [new VarTag(null, ['\\' . $daoNamespace . '\\' . $daoClassName, 'null'])]));
383
+            $daoInstanceProperty->setDocBlock(new DocBlockGenerator(null, null, [new VarTag(null, ['\\'.$daoNamespace.'\\'.$daoClassName, 'null'])]));
384 384
             $class->addPropertyFromGenerator($daoInstanceProperty);
385 385
 
386 386
             $fullClassNameVarExport = var_export($daoNamespace.'\\'.$daoClassName, true);
@@ -393,7 +393,7 @@  discard block
 block discarded – undo
393 393
 BODY;
394 394
 
395 395
             $getterMethod = new MethodGenerator(
396
-                'get' . $daoClassName,
396
+                'get'.$daoClassName,
397 397
                 [],
398 398
                 MethodGenerator::FLAG_PUBLIC,
399 399
                 $getterBody
@@ -405,10 +405,10 @@  discard block
 block discarded – undo
405 405
             }
406 406
 
407 407
             $setterMethod = new MethodGenerator(
408
-                'set' . $daoClassName,
409
-                [new ParameterGenerator($daoInstanceName, '\\' . $daoNamespace . '\\' . $daoClassName)],
408
+                'set'.$daoClassName,
409
+                [new ParameterGenerator($daoInstanceName, '\\'.$daoNamespace.'\\'.$daoClassName)],
410 410
                 MethodGenerator::FLAG_PUBLIC,
411
-                '$this->' . $daoInstanceName . ' = $' . $daoInstanceName . ';'
411
+                '$this->'.$daoInstanceName.' = $'.$daoInstanceName.';'
412 412
             );
413 413
             $setterMethod->setReturnType('void');
414 414
             $setterMethod = $this->configuration->getCodeGeneratorListener()->onDaoFactorySetterGenerated($setterMethod, $beanDescriptor, $this->configuration, $class);
@@ -428,7 +428,7 @@  discard block
 block discarded – undo
428 428
             $fileContent = $this->psr2Fix($fileContent);
429 429
             // Add the declare strict-types directive
430 430
             $commentEnd = strpos($fileContent, ' */') + 3;
431
-            $fileContent = substr($fileContent, 0, $commentEnd) . "\n\ndeclare(strict_types=1);" . substr($fileContent, $commentEnd + 1);
431
+            $fileContent = substr($fileContent, 0, $commentEnd)."\n\ndeclare(strict_types=1);".substr($fileContent, $commentEnd + 1);
432 432
 
433 433
             $this->dumpFile($possibleFileName, $fileContent);
434 434
         }
@@ -535,7 +535,7 @@  discard block
 block discarded – undo
535 535
         $map = [
536 536
             Type::TARRAY => 'array',
537 537
             Type::SIMPLE_ARRAY => 'array',
538
-            'json' => 'array',  // 'json' is supported from Doctrine DBAL 2.6 only.
538
+            'json' => 'array', // 'json' is supported from Doctrine DBAL 2.6 only.
539 539
             Type::JSON_ARRAY => 'array',
540 540
             Type::BIGINT => 'string',
541 541
             Type::BOOLEAN => 'bool',
Please login to merge, or discard this patch.
src/Utils/Logs/LevelFilter.php 1 patch
Spacing   +6 added lines, -6 removed lines patch added patch discarded remove patch
@@ -19,12 +19,12 @@
 block discarded – undo
19 19
      */
20 20
     private static $levels = array(
21 21
         LogLevel::EMERGENCY, // 0
22
-        LogLevel::ALERT,     // 1
23
-        LogLevel::CRITICAL,  // 2
24
-        LogLevel::ERROR,     // 3
25
-        LogLevel::WARNING,   // 4
26
-        LogLevel::NOTICE,    // 5
27
-        LogLevel::INFO,      // 6
22
+        LogLevel::ALERT, // 1
23
+        LogLevel::CRITICAL, // 2
24
+        LogLevel::ERROR, // 3
25
+        LogLevel::WARNING, // 4
26
+        LogLevel::NOTICE, // 5
27
+        LogLevel::INFO, // 6
28 28
         LogLevel::DEBUG      // 7
29 29
     );
30 30
 
Please login to merge, or discard this patch.
src/QueryFactory/FindObjectsFromRawSqlQueryFactory.php 1 patch
Spacing   +2 added lines, -2 removed lines patch added patch discarded remove patch
@@ -214,7 +214,7 @@  discard block
 block discarded – undo
214 214
                 $alias = AbstractQueryFactory::getColumnAlias($tableName, $columnName);
215 215
                 $astColumn = [
216 216
                     'expr_type' => 'colref',
217
-                    'base_expr' => $connection->quoteIdentifier($tableName) . '.' . $connection->quoteIdentifier($columnName),
217
+                    'base_expr' => $connection->quoteIdentifier($tableName).'.'.$connection->quoteIdentifier($columnName),
218 218
                     'no_quotes' => [
219 219
                         'delim' => '.',
220 220
                         'parts' => [
@@ -302,7 +302,7 @@  discard block
 block discarded – undo
302 302
                 return $this->generateWrappedSqlCount($parsedSql);
303 303
             }
304 304
 
305
-            $countSubExpr = array_map(function (array $item) {
305
+            $countSubExpr = array_map(function(array $item) {
306 306
                 unset($item['alias']);
307 307
                 return $item;
308 308
             }, $parsedSql['SELECT']);
Please login to merge, or discard this patch.
src/QueryFactory/FindObjectsFromSqlQueryFactory.php 1 patch
Spacing   +4 added lines, -4 removed lines patch added patch discarded remove patch
@@ -49,7 +49,7 @@  discard block
 block discarded – undo
49 49
 
50 50
         // Let's compute the COUNT.
51 51
         $pkColumnNames = $this->tdbmService->getPrimaryKeyColumns($this->mainTable);
52
-        $pkColumnNames = array_map(function ($pkColumn) use ($mySqlPlatform) {
52
+        $pkColumnNames = array_map(function($pkColumn) use ($mySqlPlatform) {
53 53
             return $mySqlPlatform->quoteIdentifier($this->mainTable).'.'.$mySqlPlatform->quoteIdentifier($pkColumn);
54 54
         }, $pkColumnNames);
55 55
 
@@ -113,7 +113,7 @@  discard block
 block discarded – undo
113 113
      */
114 114
     private function getParentRelationshipForeignKeys(string $tableName): array
115 115
     {
116
-        return $this->fromCache($this->cachePrefix.'_parentrelationshipfks_'.$tableName, function () use ($tableName) {
116
+        return $this->fromCache($this->cachePrefix.'_parentrelationshipfks_'.$tableName, function() use ($tableName) {
117 117
             return $this->getParentRelationshipForeignKeysWithoutCache($tableName);
118 118
         });
119 119
     }
@@ -142,7 +142,7 @@  discard block
 block discarded – undo
142 142
      */
143 143
     private function getChildrenRelationshipForeignKeys(string $tableName) : array
144 144
     {
145
-        return $this->fromCache($this->cachePrefix.'_childrenrelationshipfks_'.$tableName, function () use ($tableName) {
145
+        return $this->fromCache($this->cachePrefix.'_childrenrelationshipfks_'.$tableName, function() use ($tableName) {
146 146
             return $this->getChildrenRelationshipForeignKeysWithoutCache($tableName);
147 147
         });
148 148
     }
@@ -157,7 +157,7 @@  discard block
 block discarded – undo
157 157
         $children = $this->schemaAnalyzer->getChildrenRelationships($tableName);
158 158
 
159 159
         if (!empty($children)) {
160
-            $fksTables = array_map(function (ForeignKeyConstraint $fk) {
160
+            $fksTables = array_map(function(ForeignKeyConstraint $fk) {
161 161
                 return $this->getChildrenRelationshipForeignKeys($fk->getLocalTableName());
162 162
             }, $children);
163 163
 
Please login to merge, or discard this patch.
src/QueryFactory/AbstractQueryFactory.php 1 patch
Spacing   +1 added lines, -1 removed lines patch added patch discarded remove patch
@@ -207,7 +207,7 @@
 block discarded – undo
207 207
         if (strlen($alias) <= 30) { // Older oracle version had a limit of 30 characters for identifiers
208 208
             return $alias;
209 209
         }
210
-        return substr($columnName, 0, 20) . crc32($tableName.'____'.$columnName);
210
+        return substr($columnName, 0, 20).crc32($tableName.'____'.$columnName);
211 211
     }
212 212
 
213 213
     abstract protected function compute(): void;
Please login to merge, or discard this patch.
src/Utils/StringUtils.php 1 patch
Spacing   +1 added lines, -1 removed lines patch added patch discarded remove patch
@@ -8,7 +8,7 @@
 block discarded – undo
8 8
 {
9 9
     public static function getValidVariableName(string $variableName): string
10 10
     {
11
-        $valid = preg_replace_callback('/^(\d+)/', static function (array $match) {
11
+        $valid = preg_replace_callback('/^(\d+)/', static function(array $match) {
12 12
             $f = new \NumberFormatter('en', \NumberFormatter::SPELLOUT);
13 13
             $number = $f->format((int) $match[0]);
14 14
             return preg_replace('/[^a-z]+/i', '_', $number);
Please login to merge, or discard this patch.