@@ -83,7 +83,7 @@ discard block |
||
| 83 | 83 | ); |
| 84 | 84 | } |
| 85 | 85 | |
| 86 | - if (! $associationMetadata->isOwningSide()) { |
|
| 86 | + if ( ! $associationMetadata->isOwningSide()) { |
|
| 87 | 87 | throw Mapping\MappingException::illegalInverseIdentifierAssociation( |
| 88 | 88 | $this->componentMetadata->getClassName(), |
| 89 | 89 | $this->fieldName |
@@ -100,7 +100,7 @@ discard block |
||
| 100 | 100 | // @todo guilhermeblanco The below block of code modifies component metadata properties, and it should be moved |
| 101 | 101 | // to the component metadata builder instead of here. |
| 102 | 102 | |
| 103 | - if (! in_array($this->fieldName, $this->componentMetadata->identifier, true)) { |
|
| 103 | + if ( ! in_array($this->fieldName, $this->componentMetadata->identifier, true)) { |
|
| 104 | 104 | $this->componentMetadata->identifier[] = $this->fieldName; |
| 105 | 105 | } |
| 106 | 106 | |
@@ -46,7 +46,7 @@ |
||
| 46 | 46 | $associationMetadata->setOwningSide(false); |
| 47 | 47 | $associationMetadata->setMappedBy($this->oneToManyAnnotation->mappedBy); |
| 48 | 48 | |
| 49 | - if (! empty($this->oneToManyAnnotation->indexBy)) { |
|
| 49 | + if ( ! empty($this->oneToManyAnnotation->indexBy)) { |
|
| 50 | 50 | $associationMetadata->setIndexedBy($this->oneToManyAnnotation->indexBy); |
| 51 | 51 | } |
| 52 | 52 | |
@@ -86,16 +86,16 @@ discard block |
||
| 86 | 86 | $associationMetadata->setFetchMode($this->getFetchMode($this->manyToManyAnnotation->fetch)); |
| 87 | 87 | $associationMetadata->setOwningSide(true); |
| 88 | 88 | |
| 89 | - if (! empty($this->manyToManyAnnotation->mappedBy)) { |
|
| 89 | + if ( ! empty($this->manyToManyAnnotation->mappedBy)) { |
|
| 90 | 90 | $associationMetadata->setMappedBy($this->manyToManyAnnotation->mappedBy); |
| 91 | 91 | $associationMetadata->setOwningSide(false); |
| 92 | 92 | } |
| 93 | 93 | |
| 94 | - if (! empty($this->manyToManyAnnotation->inversedBy)) { |
|
| 94 | + if ( ! empty($this->manyToManyAnnotation->inversedBy)) { |
|
| 95 | 95 | $associationMetadata->setInversedBy($this->manyToManyAnnotation->inversedBy); |
| 96 | 96 | } |
| 97 | 97 | |
| 98 | - if (! empty($this->manyToManyAnnotation->indexBy)) { |
|
| 98 | + if ( ! empty($this->manyToManyAnnotation->indexBy)) { |
|
| 99 | 99 | $associationMetadata->setIndexedBy($this->manyToManyAnnotation->indexBy); |
| 100 | 100 | } |
| 101 | 101 | |
@@ -113,7 +113,7 @@ discard block |
||
| 113 | 113 | $this->buildCache($associationMetadata); |
| 114 | 114 | |
| 115 | 115 | // Check for owning side to consider join column |
| 116 | - if (! $associationMetadata->isOwningSide()) { |
|
| 116 | + if ( ! $associationMetadata->isOwningSide()) { |
|
| 117 | 117 | return $associationMetadata; |
| 118 | 118 | } |
| 119 | 119 | |
@@ -90,12 +90,12 @@ discard block |
||
| 90 | 90 | protected function getTargetEntity(string $targetEntity) : string |
| 91 | 91 | { |
| 92 | 92 | // Validate if target entity is defined |
| 93 | - if (! $targetEntity) { |
|
| 93 | + if ( ! $targetEntity) { |
|
| 94 | 94 | throw Mapping\MappingException::missingTargetEntity($this->fieldName); |
| 95 | 95 | } |
| 96 | 96 | |
| 97 | 97 | // Validate that target entity exists |
| 98 | - if (! (class_exists($targetEntity) || interface_exists($targetEntity))) { |
|
| 98 | + if ( ! (class_exists($targetEntity) || interface_exists($targetEntity))) { |
|
| 99 | 99 | throw Mapping\MappingException::invalidTargetEntityClass( |
| 100 | 100 | $targetEntity, |
| 101 | 101 | $this->componentMetadata->getClassName(), |
@@ -150,7 +150,7 @@ discard block |
||
| 150 | 150 | { |
| 151 | 151 | $fetchModeConstant = sprintf('%s::%s', Mapping\FetchMode::class, $fetchMode); |
| 152 | 152 | |
| 153 | - if (! defined($fetchModeConstant)) { |
|
| 153 | + if ( ! defined($fetchModeConstant)) { |
|
| 154 | 154 | throw Mapping\MappingException::invalidFetchMode($this->componentMetadata->getClassName(), $fetchMode); |
| 155 | 155 | } |
| 156 | 156 | |
@@ -41,7 +41,7 @@ |
||
| 41 | 41 | $associationMetadata->setFetchMode($this->getFetchMode($this->manyToOneAnnotation->fetch)); |
| 42 | 42 | $associationMetadata->setOwningSide(true); |
| 43 | 43 | |
| 44 | - if (! empty($this->manyToOneAnnotation->inversedBy)) { |
|
| 44 | + if ( ! empty($this->manyToOneAnnotation->inversedBy)) { |
|
| 45 | 45 | $associationMetadata->setInversedBy($this->manyToOneAnnotation->inversedBy); |
| 46 | 46 | } |
| 47 | 47 | |
@@ -229,11 +229,11 @@ discard block |
||
| 229 | 229 | $this->setCache(clone $parent->cache); |
| 230 | 230 | } |
| 231 | 231 | |
| 232 | - if (! empty($parent->lifecycleCallbacks)) { |
|
| 232 | + if ( ! empty($parent->lifecycleCallbacks)) { |
|
| 233 | 233 | $this->lifecycleCallbacks = $parent->lifecycleCallbacks; |
| 234 | 234 | } |
| 235 | 235 | |
| 236 | - if (! empty($parent->entityListeners)) { |
|
| 236 | + if ( ! empty($parent->entityListeners)) { |
|
| 237 | 237 | $this->entityListeners = $parent->entityListeners; |
| 238 | 238 | } |
| 239 | 239 | } |
@@ -300,7 +300,7 @@ discard block |
||
| 300 | 300 | */ |
| 301 | 301 | public function __toString() |
| 302 | 302 | { |
| 303 | - return self::class . '@' . spl_object_id($this); |
|
| 303 | + return self::class.'@'.spl_object_id($this); |
|
| 304 | 304 | } |
| 305 | 305 | |
| 306 | 306 | /** |
@@ -387,7 +387,7 @@ discard block |
||
| 387 | 387 | // Restore ReflectionClass and properties |
| 388 | 388 | $this->reflectionClass = $reflectionService->getClass($this->className); |
| 389 | 389 | |
| 390 | - if (! $this->reflectionClass) { |
|
| 390 | + if ( ! $this->reflectionClass) { |
|
| 391 | 391 | return; |
| 392 | 392 | } |
| 393 | 393 | |
@@ -416,11 +416,11 @@ discard block |
||
| 416 | 416 | */ |
| 417 | 417 | public function isIdentifier(string $fieldName) : bool |
| 418 | 418 | { |
| 419 | - if (! $this->identifier) { |
|
| 419 | + if ( ! $this->identifier) { |
|
| 420 | 420 | return false; |
| 421 | 421 | } |
| 422 | 422 | |
| 423 | - if (! $this->isIdentifierComposite()) { |
|
| 423 | + if ( ! $this->isIdentifierComposite()) { |
|
| 424 | 424 | return $fieldName === $this->identifier[0]; |
| 425 | 425 | } |
| 426 | 426 | |
@@ -444,11 +444,11 @@ discard block |
||
| 444 | 444 | } |
| 445 | 445 | |
| 446 | 446 | // Verify & complete identifier mapping |
| 447 | - if (! $this->identifier) { |
|
| 447 | + if ( ! $this->identifier) { |
|
| 448 | 448 | throw MappingException::identifierRequired($this->className); |
| 449 | 449 | } |
| 450 | 450 | |
| 451 | - $explicitlyGeneratedProperties = array_filter($this->properties, static function (Property $property) : bool { |
|
| 451 | + $explicitlyGeneratedProperties = array_filter($this->properties, static function(Property $property) : bool { |
|
| 452 | 452 | return $property instanceof FieldMetadata |
| 453 | 453 | && $property->isPrimaryKey() |
| 454 | 454 | && $property->hasValueGenerator(); |
@@ -469,7 +469,7 @@ discard block |
||
| 469 | 469 | foreach ($this->lifecycleCallbacks as $callbacks) { |
| 470 | 470 | /** @var array $callbacks */ |
| 471 | 471 | foreach ($callbacks as $callbackFuncName) { |
| 472 | - if (! $reflectionService->hasPublicMethod($this->className, $callbackFuncName)) { |
|
| 472 | + if ( ! $reflectionService->hasPublicMethod($this->className, $callbackFuncName)) { |
|
| 473 | 473 | throw MappingException::lifecycleCallbackMethodNotFound($this->className, $callbackFuncName); |
| 474 | 474 | } |
| 475 | 475 | } |
@@ -498,7 +498,7 @@ discard block |
||
| 498 | 498 | throw MappingException::singleIdNotAllowedOnCompositePrimaryKey($this->className); |
| 499 | 499 | } |
| 500 | 500 | |
| 501 | - if (! isset($this->identifier[0])) { |
|
| 501 | + if ( ! isset($this->identifier[0])) { |
|
| 502 | 502 | throw MappingException::noIdDefined($this->className); |
| 503 | 503 | } |
| 504 | 504 | |
@@ -557,7 +557,7 @@ discard block |
||
| 557 | 557 | // Association defined as Id field |
| 558 | 558 | $targetClass = $em->getClassMetadata($property->getTargetEntity()); |
| 559 | 559 | |
| 560 | - if (! $property->isOwningSide()) { |
|
| 560 | + if ( ! $property->isOwningSide()) { |
|
| 561 | 561 | $property = $targetClass->getProperty($property->getMappedBy()); |
| 562 | 562 | $targetClass = $em->getClassMetadata($property->getTargetEntity()); |
| 563 | 563 | } |
@@ -571,7 +571,7 @@ discard block |
||
| 571 | 571 | $columnName = $joinColumn->getColumnName(); |
| 572 | 572 | $referencedColumnName = $joinColumn->getReferencedColumnName(); |
| 573 | 573 | |
| 574 | - if (! $joinColumn->getType()) { |
|
| 574 | + if ( ! $joinColumn->getType()) { |
|
| 575 | 575 | $joinColumn->setType(PersisterHelper::getTypeOfColumn($referencedColumnName, $targetClass, $em)); |
| 576 | 576 | } |
| 577 | 577 | |
@@ -605,10 +605,10 @@ discard block |
||
| 605 | 605 | { |
| 606 | 606 | $schema = $this->getSchemaName() === null |
| 607 | 607 | ? '' |
| 608 | - : $this->getSchemaName() . '_'; |
|
| 608 | + : $this->getSchemaName().'_'; |
|
| 609 | 609 | |
| 610 | 610 | // replace dots with underscores because PostgreSQL creates temporary tables in a special schema |
| 611 | - return $schema . $this->getTableName() . '_id_tmp'; |
|
| 611 | + return $schema.$this->getTableName().'_id_tmp'; |
|
| 612 | 612 | } |
| 613 | 613 | |
| 614 | 614 | /** |
@@ -642,7 +642,7 @@ discard block |
||
| 642 | 642 | */ |
| 643 | 643 | public function setInheritanceType($type) : void |
| 644 | 644 | { |
| 645 | - if (! $this->isInheritanceType($type)) { |
|
| 645 | + if ( ! $this->isInheritanceType($type)) { |
|
| 646 | 646 | throw MappingException::invalidInheritanceType($this->className, $type); |
| 647 | 647 | } |
| 648 | 648 | |
@@ -660,7 +660,7 @@ discard block |
||
| 660 | 660 | { |
| 661 | 661 | $fieldName = $property->getName(); |
| 662 | 662 | |
| 663 | - if (! isset($this->properties[$fieldName])) { |
|
| 663 | + if ( ! isset($this->properties[$fieldName])) { |
|
| 664 | 664 | throw MappingException::invalidOverrideFieldName($this->className, $fieldName); |
| 665 | 665 | } |
| 666 | 666 | |
@@ -854,7 +854,7 @@ discard block |
||
| 854 | 854 | $inheritedProperty = $declaringClass->isMappedSuperclass ? clone $property : $property; |
| 855 | 855 | |
| 856 | 856 | if ($inheritedProperty instanceof FieldMetadata) { |
| 857 | - if (! $declaringClass->isMappedSuperclass) { |
|
| 857 | + if ( ! $declaringClass->isMappedSuperclass) { |
|
| 858 | 858 | $inheritedProperty->setTableName($property->getTableName()); |
| 859 | 859 | } |
| 860 | 860 | |
@@ -947,11 +947,11 @@ discard block |
||
| 947 | 947 | 'method' => $methodName, |
| 948 | 948 | ]; |
| 949 | 949 | |
| 950 | - if (! class_exists($class)) { |
|
| 950 | + if ( ! class_exists($class)) { |
|
| 951 | 951 | throw MappingException::entityListenerClassNotFound($class, $this->className); |
| 952 | 952 | } |
| 953 | 953 | |
| 954 | - if (! method_exists($class, $methodName)) { |
|
| 954 | + if ( ! method_exists($class, $methodName)) { |
|
| 955 | 955 | throw MappingException::entityListenerMethodNotFound($class, $methodName, $this->className); |
| 956 | 956 | } |
| 957 | 957 | |
@@ -1019,7 +1019,7 @@ discard block |
||
| 1019 | 1019 | return; |
| 1020 | 1020 | } |
| 1021 | 1021 | |
| 1022 | - if (! (class_exists($className) || interface_exists($className))) { |
|
| 1022 | + if ( ! (class_exists($className) || interface_exists($className))) { |
|
| 1023 | 1023 | throw MappingException::invalidClassInDiscriminatorMap($className, $this->className); |
| 1024 | 1024 | } |
| 1025 | 1025 | |
@@ -210,7 +210,7 @@ discard block |
||
| 210 | 210 | return $this->classNames; |
| 211 | 211 | } |
| 212 | 212 | |
| 213 | - if (! $this->paths) { |
|
| 213 | + if ( ! $this->paths) { |
|
| 214 | 214 | throw Mapping\MappingException::pathRequired(); |
| 215 | 215 | } |
| 216 | 216 | |
@@ -218,7 +218,7 @@ discard block |
||
| 218 | 218 | $includedFiles = []; |
| 219 | 219 | |
| 220 | 220 | foreach ($this->paths as $path) { |
| 221 | - if (! is_dir($path)) { |
|
| 221 | + if ( ! is_dir($path)) { |
|
| 222 | 222 | throw Mapping\MappingException::fileMappingDriversRequireConfiguredDirectoryPath($path); |
| 223 | 223 | } |
| 224 | 224 | |
@@ -227,14 +227,14 @@ discard block |
||
| 227 | 227 | new RecursiveDirectoryIterator($path, FilesystemIterator::SKIP_DOTS), |
| 228 | 228 | RecursiveIteratorIterator::LEAVES_ONLY |
| 229 | 229 | ), |
| 230 | - '/^.+' . preg_quote($this->fileExtension) . '$/i', |
|
| 230 | + '/^.+'.preg_quote($this->fileExtension).'$/i', |
|
| 231 | 231 | RecursiveRegexIterator::GET_MATCH |
| 232 | 232 | ); |
| 233 | 233 | |
| 234 | 234 | foreach ($iterator as $file) { |
| 235 | 235 | $sourceFile = $file[0]; |
| 236 | 236 | |
| 237 | - if (! preg_match('(^phar:)i', $sourceFile)) { |
|
| 237 | + if ( ! preg_match('(^phar:)i', $sourceFile)) { |
|
| 238 | 238 | $sourceFile = realpath($sourceFile); |
| 239 | 239 | } |
| 240 | 240 | |
@@ -412,7 +412,7 @@ discard block |
||
| 412 | 412 | if ($parent && $parent->inheritanceType === Mapping\InheritanceType::SINGLE_TABLE) { |
| 413 | 413 | // Handle the case where a middle mapped super class inherits from a single table inheritance tree. |
| 414 | 414 | do { |
| 415 | - if (! $parent->isMappedSuperclass) { |
|
| 415 | + if ( ! $parent->isMappedSuperclass) { |
|
| 416 | 416 | $metadata->setTable($parent->table); |
| 417 | 417 | |
| 418 | 418 | break; |
@@ -706,7 +706,7 @@ discard block |
||
| 706 | 706 | ]; |
| 707 | 707 | |
| 708 | 708 | foreach ($entityListenersAnnot->value as $listenerClassName) { |
| 709 | - if (! class_exists($listenerClassName)) { |
|
| 709 | + if ( ! class_exists($listenerClassName)) { |
|
| 710 | 710 | throw Mapping\MappingException::entityListenerClassNotFound( |
| 711 | 711 | $listenerClassName, |
| 712 | 712 | $metadata->getClassName() |
@@ -748,7 +748,7 @@ discard block |
||
| 748 | 748 | $fieldName = $associationOverrideAnnotation->name; |
| 749 | 749 | $property = $metadata->getProperty($fieldName); |
| 750 | 750 | |
| 751 | - if (! $property) { |
|
| 751 | + if ( ! $property) { |
|
| 752 | 752 | throw Mapping\MappingException::invalidOverrideFieldName($metadata->getClassName(), $fieldName); |
| 753 | 753 | } |
| 754 | 754 | |
@@ -805,7 +805,7 @@ discard block |
||
| 805 | 805 | |
| 806 | 806 | // Check for fetch |
| 807 | 807 | if ($associationOverrideAnnotation->fetch) { |
| 808 | - $override->setFetchMode(constant(Mapping\FetchMode::class . '::' . $associationOverrideAnnotation->fetch)); |
|
| 808 | + $override->setFetchMode(constant(Mapping\FetchMode::class.'::'.$associationOverrideAnnotation->fetch)); |
|
| 809 | 809 | } |
| 810 | 810 | |
| 811 | 811 | $metadata->setPropertyOverride($override); |
@@ -826,7 +826,7 @@ discard block |
||
| 826 | 826 | $fieldName = $attributeOverrideAnnotation->name; |
| 827 | 827 | $property = $metadata->getProperty($fieldName); |
| 828 | 828 | |
| 829 | - if (! $property) { |
|
| 829 | + if ( ! $property) { |
|
| 830 | 830 | throw Mapping\MappingException::invalidOverrideFieldName($metadata->getClassName(), $fieldName); |
| 831 | 831 | } |
| 832 | 832 | |
@@ -892,7 +892,7 @@ discard block |
||
| 892 | 892 | { |
| 893 | 893 | $fetchModeConstant = sprintf('%s::%s', Mapping\FetchMode::class, $fetchMode); |
| 894 | 894 | |
| 895 | - if (! defined($fetchModeConstant)) { |
|
| 895 | + if ( ! defined($fetchModeConstant)) { |
|
| 896 | 896 | throw Mapping\MappingException::invalidFetchMode($className, $fetchMode); |
| 897 | 897 | } |
| 898 | 898 | |
@@ -907,7 +907,7 @@ discard block |
||
| 907 | 907 | $classAnnotations = $this->reader->getClassAnnotations($reflectionClass); |
| 908 | 908 | |
| 909 | 909 | foreach ($classAnnotations as $key => $annot) { |
| 910 | - if (! is_numeric($key)) { |
|
| 910 | + if ( ! is_numeric($key)) { |
|
| 911 | 911 | continue; |
| 912 | 912 | } |
| 913 | 913 | |
@@ -925,7 +925,7 @@ discard block |
||
| 925 | 925 | $propertyAnnotations = $this->reader->getPropertyAnnotations($reflectionProperty); |
| 926 | 926 | |
| 927 | 927 | foreach ($propertyAnnotations as $key => $annot) { |
| 928 | - if (! is_numeric($key)) { |
|
| 928 | + if ( ! is_numeric($key)) { |
|
| 929 | 929 | continue; |
| 930 | 930 | } |
| 931 | 931 | |
@@ -943,7 +943,7 @@ discard block |
||
| 943 | 943 | $methodAnnotations = $this->reader->getMethodAnnotations($reflectionMethod); |
| 944 | 944 | |
| 945 | 945 | foreach ($methodAnnotations as $key => $annot) { |
| 946 | - if (! is_numeric($key)) { |
|
| 946 | + if ( ! is_numeric($key)) { |
|
| 947 | 947 | continue; |
| 948 | 948 | } |
| 949 | 949 | |
@@ -78,7 +78,7 @@ discard block |
||
| 78 | 78 | if ($parent && $parent->inheritanceType === Mapping\InheritanceType::SINGLE_TABLE) { |
| 79 | 79 | // Handle the case where a middle mapped super class inherits from a single table inheritance tree. |
| 80 | 80 | do { |
| 81 | - if (! $parent->isMappedSuperclass) { |
|
| 81 | + if ( ! $parent->isMappedSuperclass) { |
|
| 82 | 82 | $metadata->setTable($parent->table); |
| 83 | 83 | |
| 84 | 84 | break; |
@@ -436,7 +436,7 @@ discard block |
||
| 436 | 436 | $fieldName = (string) $overrideElement['name']; |
| 437 | 437 | $property = $metadata->getProperty($fieldName); |
| 438 | 438 | |
| 439 | - if (! $property) { |
|
| 439 | + if ( ! $property) { |
|
| 440 | 440 | throw Mapping\MappingException::invalidOverrideFieldName($metadata->getClassName(), $fieldName); |
| 441 | 441 | } |
| 442 | 442 | |
@@ -472,7 +472,7 @@ discard block |
||
| 472 | 472 | $fieldName = (string) $overrideElement['name']; |
| 473 | 473 | $property = $metadata->getProperty($fieldName); |
| 474 | 474 | |
| 475 | - if (! $property) { |
|
| 475 | + if ( ! $property) { |
|
| 476 | 476 | throw Mapping\MappingException::invalidOverrideFieldName($metadata->getClassName(), $fieldName); |
| 477 | 477 | } |
| 478 | 478 | |
@@ -534,7 +534,7 @@ discard block |
||
| 534 | 534 | // Check for fetch |
| 535 | 535 | if (isset($overrideElement['fetch'])) { |
| 536 | 536 | $override->setFetchMode( |
| 537 | - constant('Doctrine\ORM\Mapping\FetchMode::' . (string) $overrideElement['fetch']) |
|
| 537 | + constant('Doctrine\ORM\Mapping\FetchMode::'.(string) $overrideElement['fetch']) |
|
| 538 | 538 | ); |
| 539 | 539 | } |
| 540 | 540 | |
@@ -545,7 +545,7 @@ discard block |
||
| 545 | 545 | // Evaluate <lifecycle-callbacks...> |
| 546 | 546 | if (isset($xmlRoot->{'lifecycle-callbacks'})) { |
| 547 | 547 | foreach ($xmlRoot->{'lifecycle-callbacks'}->{'lifecycle-callback'} as $lifecycleCallback) { |
| 548 | - $eventName = constant(Events::class . '::' . (string) $lifecycleCallback['type']); |
|
| 548 | + $eventName = constant(Events::class.'::'.(string) $lifecycleCallback['type']); |
|
| 549 | 549 | $methodName = (string) $lifecycleCallback['method']; |
| 550 | 550 | |
| 551 | 551 | $metadata->addLifecycleCallback($eventName, $methodName); |
@@ -557,7 +557,7 @@ discard block |
||
| 557 | 557 | foreach ($xmlRoot->{'entity-listeners'}->{'entity-listener'} as $listenerElement) { |
| 558 | 558 | $listenerClassName = (string) $listenerElement['class']; |
| 559 | 559 | |
| 560 | - if (! class_exists($listenerClassName)) { |
|
| 560 | + if ( ! class_exists($listenerClassName)) { |
|
| 561 | 561 | throw Mapping\MappingException::entityListenerClassNotFound( |
| 562 | 562 | $listenerClassName, |
| 563 | 563 | $metadata->getClassName() |
@@ -51,12 +51,12 @@ discard block |
||
| 51 | 51 | $associationMetadata->setCascade(array_unique(array_merge($associationMetadata->getCascade(), ['remove']))); |
| 52 | 52 | } |
| 53 | 53 | |
| 54 | - if (! empty($this->oneToOneAnnotation->mappedBy)) { |
|
| 54 | + if ( ! empty($this->oneToOneAnnotation->mappedBy)) { |
|
| 55 | 55 | $associationMetadata->setMappedBy($this->oneToOneAnnotation->mappedBy); |
| 56 | 56 | $associationMetadata->setOwningSide(false); |
| 57 | 57 | } |
| 58 | 58 | |
| 59 | - if (! empty($this->oneToOneAnnotation->inversedBy)) { |
|
| 59 | + if ( ! empty($this->oneToOneAnnotation->inversedBy)) { |
|
| 60 | 60 | $associationMetadata->setInversedBy($this->oneToOneAnnotation->inversedBy); |
| 61 | 61 | $associationMetadata->setOwningSide(true); |
| 62 | 62 | } |
@@ -65,7 +65,7 @@ discard block |
||
| 65 | 65 | $this->buildPrimaryKey($associationMetadata); |
| 66 | 66 | |
| 67 | 67 | // Check for owning side to consider join column |
| 68 | - if (! $associationMetadata->isOwningSide()) { |
|
| 68 | + if ( ! $associationMetadata->isOwningSide()) { |
|
| 69 | 69 | return $associationMetadata; |
| 70 | 70 | } |
| 71 | 71 | |
@@ -89,7 +89,7 @@ discard block |
||
| 89 | 89 | if (count($joinColumns) === 1) { |
| 90 | 90 | $joinColumn = reset($joinColumns); |
| 91 | 91 | |
| 92 | - if (! $associationMetadata->isPrimaryKey()) { |
|
| 92 | + if ( ! $associationMetadata->isPrimaryKey()) { |
|
| 93 | 93 | $joinColumn->setUnique(true); |
| 94 | 94 | } |
| 95 | 95 | |
@@ -98,7 +98,7 @@ discard block |
||
| 98 | 98 | |
| 99 | 99 | $tableMetadata = $this->componentMetadata->table; |
| 100 | 100 | |
| 101 | - if (! $tableMetadata) { |
|
| 101 | + if ( ! $tableMetadata) { |
|
| 102 | 102 | $exception = 'ClassMetadata::setTable() has to be called before defining a one to one relationship.'; |
| 103 | 103 | |
| 104 | 104 | throw new RuntimeException($exception); |