@@ -1,6 +1,6 @@ |
||
1 | 1 | <?php |
2 | 2 | |
3 | -declare(strict_types=1); |
|
3 | +declare(strict_types = 1); |
|
4 | 4 | |
5 | 5 | namespace Doctrine\ORM\Exception; |
6 | 6 |
@@ -1,6 +1,6 @@ |
||
1 | 1 | <?php |
2 | 2 | |
3 | -declare(strict_types=1); |
|
3 | +declare(strict_types = 1); |
|
4 | 4 | |
5 | 5 | namespace Doctrine\ORM\Exception; |
6 | 6 |
@@ -1,6 +1,6 @@ |
||
1 | 1 | <?php |
2 | 2 | |
3 | -declare(strict_types=1); |
|
3 | +declare(strict_types = 1); |
|
4 | 4 | |
5 | 5 | namespace Doctrine\ORM\Exception; |
6 | 6 |
@@ -1,6 +1,6 @@ |
||
1 | 1 | <?php |
2 | 2 | |
3 | -declare(strict_types=1); |
|
3 | +declare(strict_types = 1); |
|
4 | 4 | |
5 | 5 | namespace Doctrine\ORM\Exception; |
6 | 6 |
@@ -1,6 +1,6 @@ |
||
1 | 1 | <?php |
2 | 2 | |
3 | -declare(strict_types=1); |
|
3 | +declare(strict_types = 1); |
|
4 | 4 | |
5 | 5 | namespace Doctrine\ORM\Exception; |
6 | 6 |
@@ -1,6 +1,6 @@ |
||
1 | 1 | <?php |
2 | 2 | |
3 | -declare(strict_types=1); |
|
3 | +declare(strict_types = 1); |
|
4 | 4 | |
5 | 5 | namespace Doctrine\ORM\Exception; |
6 | 6 |
@@ -1,6 +1,6 @@ |
||
1 | 1 | <?php |
2 | 2 | |
3 | -declare(strict_types=1); |
|
3 | +declare(strict_types = 1); |
|
4 | 4 | |
5 | 5 | namespace Doctrine\ORM\Exception; |
6 | 6 |
@@ -1,6 +1,6 @@ discard block |
||
1 | 1 | <?php |
2 | 2 | |
3 | -declare(strict_types=1); |
|
3 | +declare(strict_types = 1); |
|
4 | 4 | |
5 | 5 | namespace Doctrine\ORM\Tools; |
6 | 6 | |
@@ -176,11 +176,11 @@ discard block |
||
176 | 176 | $pkColumns = []; |
177 | 177 | |
178 | 178 | foreach ($class->getDeclaredPropertiesIterator() as $fieldName => $property) { |
179 | - if (! ($property instanceof FieldMetadata)) { |
|
179 | + if ( ! ($property instanceof FieldMetadata)) { |
|
180 | 180 | continue; |
181 | 181 | } |
182 | 182 | |
183 | - if (! $class->isInheritedProperty($fieldName)) { |
|
183 | + if ( ! $class->isInheritedProperty($fieldName)) { |
|
184 | 184 | $columnName = $this->platform->quoteIdentifier($property->getColumnName()); |
185 | 185 | |
186 | 186 | $this->gatherColumn($class, $property, $table); |
@@ -215,7 +215,7 @@ discard block |
||
215 | 215 | } |
216 | 216 | } |
217 | 217 | |
218 | - if (! empty($inheritedKeyColumns)) { |
|
218 | + if ( ! empty($inheritedKeyColumns)) { |
|
219 | 219 | // Add a FK constraint on the ID column |
220 | 220 | $rootClass = $this->em->getClassMetadata($class->getRootClassName()); |
221 | 221 | |
@@ -260,7 +260,7 @@ discard block |
||
260 | 260 | } |
261 | 261 | } |
262 | 262 | |
263 | - if (! $table->hasIndex('primary')) { |
|
263 | + if ( ! $table->hasIndex('primary')) { |
|
264 | 264 | $table->setPrimaryKey($pkColumns); |
265 | 265 | } |
266 | 266 | |
@@ -320,7 +320,7 @@ discard block |
||
320 | 320 | $processedClasses[$class->getClassName()] = true; |
321 | 321 | |
322 | 322 | foreach ($class->getDeclaredPropertiesIterator() as $property) { |
323 | - if (! $property instanceof FieldMetadata |
|
323 | + if ( ! $property instanceof FieldMetadata |
|
324 | 324 | || ! $property->hasValueGenerator() |
325 | 325 | || $property->getValueGenerator()->getType() !== GeneratorType::SEQUENCE |
326 | 326 | || $class->getClassName() !== $class->getRootClassName()) { |
@@ -329,7 +329,7 @@ discard block |
||
329 | 329 | |
330 | 330 | $quotedName = $this->platform->quoteIdentifier($property->getValueGenerator()->getDefinition()['sequenceName']); |
331 | 331 | |
332 | - if (! $schema->hasSequence($quotedName)) { |
|
332 | + if ( ! $schema->hasSequence($quotedName)) { |
|
333 | 333 | $schema->createSequence($quotedName, $property->getValueGenerator()->getDefinition()['allocationSize']); |
334 | 334 | } |
335 | 335 | } |
@@ -342,7 +342,7 @@ discard block |
||
342 | 342 | } |
343 | 343 | } |
344 | 344 | |
345 | - if (! $this->platform->supportsSchemas() && ! $this->platform->canEmulateSchemas()) { |
|
345 | + if ( ! $this->platform->supportsSchemas() && ! $this->platform->canEmulateSchemas()) { |
|
346 | 346 | $schema->visit(new RemoveNamespacedAssets()); |
347 | 347 | } |
348 | 348 | |
@@ -381,7 +381,7 @@ discard block |
||
381 | 381 | break; |
382 | 382 | } |
383 | 383 | |
384 | - if (! empty($discrColumn->getColumnDefinition())) { |
|
384 | + if ( ! empty($discrColumn->getColumnDefinition())) { |
|
385 | 385 | $options['columnDefinition'] = $discrColumn->getColumnDefinition(); |
386 | 386 | } |
387 | 387 | |
@@ -399,7 +399,7 @@ discard block |
||
399 | 399 | $pkColumns = []; |
400 | 400 | |
401 | 401 | foreach ($class->getDeclaredPropertiesIterator() as $fieldName => $property) { |
402 | - if (! ($property instanceof FieldMetadata)) { |
|
402 | + if ( ! ($property instanceof FieldMetadata)) { |
|
403 | 403 | continue; |
404 | 404 | } |
405 | 405 | |
@@ -514,7 +514,7 @@ discard block |
||
514 | 514 | private function gatherRelationsSql($class, $table, $schema, &$addedFks, &$blacklistedFks) |
515 | 515 | { |
516 | 516 | foreach ($class->getDeclaredPropertiesIterator() as $fieldName => $property) { |
517 | - if (! ($property instanceof AssociationMetadata)) { |
|
517 | + if ( ! ($property instanceof AssociationMetadata)) { |
|
518 | 518 | continue; |
519 | 519 | } |
520 | 520 | |
@@ -522,7 +522,7 @@ discard block |
||
522 | 522 | continue; |
523 | 523 | } |
524 | 524 | |
525 | - if (! $property->isOwningSide()) { |
|
525 | + if ( ! $property->isOwningSide()) { |
|
526 | 526 | continue; |
527 | 527 | } |
528 | 528 | |
@@ -612,7 +612,7 @@ discard block |
||
612 | 612 | $idColumns = $class->getIdentifierColumns($this->em); |
613 | 613 | $idColumnNameList = array_keys($idColumns); |
614 | 614 | |
615 | - if (! in_array($referencedColumnName, $idColumnNameList, true)) { |
|
615 | + if ( ! in_array($referencedColumnName, $idColumnNameList, true)) { |
|
616 | 616 | return null; |
617 | 617 | } |
618 | 618 | |
@@ -620,7 +620,7 @@ discard block |
||
620 | 620 | foreach ($class->getIdentifierFieldNames() as $fieldName) { |
621 | 621 | $property = $class->getProperty($fieldName); |
622 | 622 | |
623 | - if (! ($property instanceof AssociationMetadata)) { |
|
623 | + if ( ! ($property instanceof AssociationMetadata)) { |
|
624 | 624 | continue; |
625 | 625 | } |
626 | 626 | |
@@ -676,7 +676,7 @@ discard block |
||
676 | 676 | $joinColumn->getReferencedColumnName() |
677 | 677 | ); |
678 | 678 | |
679 | - if (! $definingClass) { |
|
679 | + if ( ! $definingClass) { |
|
680 | 680 | throw MissingColumnException::fromColumnSourceAndTarget( |
681 | 681 | $joinColumn->getReferencedColumnName(), |
682 | 682 | $mapping->getSourceEntity(), |
@@ -691,14 +691,14 @@ discard block |
||
691 | 691 | $localColumns[] = $quotedColumnName; |
692 | 692 | $foreignColumns[] = $quotedReferencedColumnName; |
693 | 693 | |
694 | - if (! $theJoinTable->hasColumn($quotedColumnName)) { |
|
694 | + if ( ! $theJoinTable->hasColumn($quotedColumnName)) { |
|
695 | 695 | // Only add the column to the table if it does not exist already. |
696 | 696 | // It might exist already if the foreign key is mapped into a regular |
697 | 697 | // property as well. |
698 | 698 | $property = $definingClass->getProperty($referencedFieldName); |
699 | 699 | $columnDef = null; |
700 | 700 | |
701 | - if (! empty($joinColumn->getColumnDefinition())) { |
|
701 | + if ( ! empty($joinColumn->getColumnDefinition())) { |
|
702 | 702 | $columnDef = $joinColumn->getColumnDefinition(); |
703 | 703 | } elseif ($property->getColumnDefinition()) { |
704 | 704 | $columnDef = $property->getColumnDefinition(); |
@@ -732,7 +732,7 @@ discard block |
||
732 | 732 | $uniqueConstraints[] = ['columns' => [$quotedColumnName]]; |
733 | 733 | } |
734 | 734 | |
735 | - if (! empty($joinColumn->getOnDelete())) { |
|
735 | + if ( ! empty($joinColumn->getOnDelete())) { |
|
736 | 736 | $fkOptions['onDelete'] = $joinColumn->getOnDelete(); |
737 | 737 | } |
738 | 738 | } |
@@ -743,7 +743,7 @@ discard block |
||
743 | 743 | $theJoinTable->addUniqueIndex($unique['columns'], is_numeric($indexName) ? null : $indexName); |
744 | 744 | } |
745 | 745 | |
746 | - $compositeName = $theJoinTable->getName() . '.' . implode('', $localColumns); |
|
746 | + $compositeName = $theJoinTable->getName().'.'.implode('', $localColumns); |
|
747 | 747 | |
748 | 748 | if (isset($addedFks[$compositeName]) |
749 | 749 | && ($foreignTableName !== $addedFks[$compositeName]['foreignTableName'] |
@@ -760,7 +760,7 @@ discard block |
||
760 | 760 | } |
761 | 761 | |
762 | 762 | $blacklistedFks[$compositeName] = true; |
763 | - } elseif (! isset($blacklistedFks[$compositeName])) { |
|
763 | + } elseif ( ! isset($blacklistedFks[$compositeName])) { |
|
764 | 764 | $addedFks[$compositeName] = [ |
765 | 765 | 'foreignTableName' => $foreignTableName, |
766 | 766 | 'foreignColumns' => $foreignColumns, |
@@ -842,7 +842,7 @@ discard block |
||
842 | 842 | $fullSchema = $sm->createSchema(); |
843 | 843 | |
844 | 844 | foreach ($fullSchema->getTables() as $table) { |
845 | - if (! $schema->hasTable($table->getName())) { |
|
845 | + if ( ! $schema->hasTable($table->getName())) { |
|
846 | 846 | foreach ($table->getForeignKeys() as $foreignKey) { |
847 | 847 | /* @var $foreignKey \Doctrine\DBAL\Schema\ForeignKeyConstraint */ |
848 | 848 | if ($schema->hasTable($foreignKey->getForeignTableName())) { |
@@ -867,7 +867,7 @@ discard block |
||
867 | 867 | if ($table->hasPrimaryKey()) { |
868 | 868 | $columns = $table->getPrimaryKey()->getColumns(); |
869 | 869 | if (count($columns) === 1) { |
870 | - $checkSequence = $table->getName() . '_' . $columns[0] . '_seq'; |
|
870 | + $checkSequence = $table->getName().'_'.$columns[0].'_seq'; |
|
871 | 871 | if ($fullSchema->hasSequence($checkSequence)) { |
872 | 872 | $visitor->acceptSequence($fullSchema->getSequence($checkSequence)); |
873 | 873 | } |