Completed
Pull Request — master (#5669)
by Jeremy
48:42 queued 40:04
created
lib/Doctrine/ORM/Mapping/DefaultQuoteStrategy.php 1 patch
Spacing   +7 added lines, -7 removed lines patch added patch discarded remove patch
@@ -49,10 +49,10 @@  discard block
 block discarded – undo
49 49
         $tableName = $class->table['name'];
50 50
 
51 51
         if ( ! empty($class->table['schema'])) {
52
-            $tableName = $class->table['schema'] . '.' . $class->table['name'];
52
+            $tableName = $class->table['schema'].'.'.$class->table['name'];
53 53
 
54 54
             if ( ! $platform->supportsSchemas() && $platform->canEmulateSchemas()) {
55
-                $tableName = $class->table['schema'] . '__' . $class->table['name'];
55
+                $tableName = $class->table['schema'].'__'.$class->table['name'];
56 56
             }
57 57
         }
58 58
 
@@ -99,7 +99,7 @@  discard block
 block discarded – undo
99 99
         $schema = '';
100 100
 
101 101
         if (isset($association['joinTable']['schema'])) {
102
-            $schema = $association['joinTable']['schema'] . '.';
102
+            $schema = $association['joinTable']['schema'].'.';
103 103
         }
104 104
 
105 105
         $tableName = $association['joinTable']['name'];
@@ -108,7 +108,7 @@  discard block
 block discarded – undo
108 108
             $tableName = $platform->quoteIdentifier($tableName);
109 109
         }
110 110
 
111
-        return $schema . $tableName;
111
+        return $schema.$tableName;
112 112
     }
113 113
 
114 114
     /**
@@ -128,7 +128,7 @@  discard block
 block discarded – undo
128 128
             // Association defined as Id field
129 129
             $joinColumns            = $class->associationMappings[$fieldName]['joinColumns'];
130 130
             $assocQuotedColumnNames = array_map(
131
-                function ($joinColumn) use ($platform)
131
+                function($joinColumn) use ($platform)
132 132
                 {
133 133
                     return isset($joinColumn['quoted'])
134 134
                         ? $platform->quoteIdentifier($joinColumn['name'])
@@ -153,10 +153,10 @@  discard block
 block discarded – undo
153 153
         //     If the alias is to long, characters are cut off from the beginning.
154 154
         // 3 ) Strip non alphanumeric characters
155 155
         // 4 ) Prefix with "_" if the result its numeric
156
-        $columnName = $columnName . '_' . $counter;
156
+        $columnName = $columnName.'_'.$counter;
157 157
         $columnName = substr($columnName, -$platform->getMaxIdentifierLength());
158 158
         $columnName = preg_replace('/[^A-Za-z0-9_]/', '', $columnName);
159
-        $columnName = is_numeric($columnName) ? '_' . $columnName : $columnName;
159
+        $columnName = is_numeric($columnName) ? '_'.$columnName : $columnName;
160 160
 
161 161
         return $platform->getSQLResultCasing($columnName);
162 162
     }
Please login to merge, or discard this patch.
lib/Doctrine/ORM/Mapping/Reflection/ReflectionPropertiesGetter.php 1 patch
Spacing   +2 added lines, -2 removed lines patch added patch discarded remove patch
@@ -155,9 +155,9 @@
 block discarded – undo
155 155
         }
156 156
 
157 157
         if ($property->isProtected()) {
158
-            return "\0*\0" . $propertyName;
158
+            return "\0*\0".$propertyName;
159 159
         }
160 160
 
161
-        return "\0" . $property->getDeclaringClass()->getName() . "\0" . $propertyName;
161
+        return "\0".$property->getDeclaringClass()->getName()."\0".$propertyName;
162 162
     }
163 163
 }
Please login to merge, or discard this patch.
lib/Doctrine/ORM/Mapping/ClassMetadataInfo.php 3 patches
Indentation   +1 added lines, -1 removed lines patch added patch discarded remove patch
@@ -1431,7 +1431,7 @@
 block discarded – undo
1431 1431
 
1432 1432
         if (Type::hasType($mapping['type']) && Type::getType($mapping['type'])->canRequireSQLConversion()) {
1433 1433
             if (isset($mapping['id']) && $mapping['id'] === true) {
1434
-                 throw MappingException::sqlConversionNotAllowedForIdentifiers($this->name, $mapping['fieldName'], $mapping['type']);
1434
+                    throw MappingException::sqlConversionNotAllowedForIdentifiers($this->name, $mapping['fieldName'], $mapping['type']);
1435 1435
             }
1436 1436
 
1437 1437
             $mapping['requireSQLConversion'] = true;
Please login to merge, or discard this patch.
Spacing   +32 added lines, -32 removed lines patch added patch discarded remove patch
@@ -696,7 +696,7 @@  discard block
 block discarded – undo
696 696
     public function getSingleIdReflectionProperty()
697 697
     {
698 698
         if ($this->isIdentifierComposite) {
699
-            throw new BadMethodCallException("Class " . $this->name . " has a composite identifier.");
699
+            throw new BadMethodCallException("Class ".$this->name." has a composite identifier.");
700 700
         }
701 701
 
702 702
         return $this->reflFields[$this->identifier[0]];
@@ -791,7 +791,7 @@  discard block
 block discarded – undo
791 791
      */
792 792
     public function __toString()
793 793
     {
794
-        return __CLASS__ . '@' . spl_object_hash($this);
794
+        return __CLASS__.'@'.spl_object_hash($this);
795 795
     }
796 796
 
797 797
     /**
@@ -1020,7 +1020,7 @@  discard block
 block discarded – undo
1020 1020
     public function validateAssociations()
1021 1021
     {
1022 1022
         foreach ($this->associationMappings as $mapping) {
1023
-            if ( ! ClassLoader::classExists($mapping['targetEntity']) ) {
1023
+            if ( ! ClassLoader::classExists($mapping['targetEntity'])) {
1024 1024
                 throw MappingException::invalidTargetEntityClass($mapping['targetEntity'], $this->name, $mapping['fieldName']);
1025 1025
             }
1026 1026
         }
@@ -1080,7 +1080,7 @@  discard block
 block discarded – undo
1080 1080
      */
1081 1081
     public function enableAssociationCache($fieldName, array $cache)
1082 1082
     {
1083
-        $this->associationMappings[$fieldName]['cache'] = $this->getAssociationCacheDefaults ($fieldName, $cache);
1083
+        $this->associationMappings[$fieldName]['cache'] = $this->getAssociationCacheDefaults($fieldName, $cache);
1084 1084
     }
1085 1085
 
1086 1086
     /**
@@ -1098,7 +1098,7 @@  discard block
 block discarded – undo
1098 1098
         }
1099 1099
 
1100 1100
         if ( ! isset($cache['region'])) {
1101
-            $cache['region'] = strtolower(str_replace('\\', '_', $this->rootEntityName)) . '__' . $fieldName;
1101
+            $cache['region'] = strtolower(str_replace('\\', '_', $this->rootEntityName)).'__'.$fieldName;
1102 1102
         }
1103 1103
 
1104 1104
         return $cache;
@@ -1461,7 +1461,7 @@  discard block
 block discarded – undo
1461 1461
         $mapping['isOwningSide'] = true; // assume owning side until we hit mappedBy
1462 1462
 
1463 1463
         // unset optional indexBy attribute if its empty
1464
-        if ( ! isset($mapping['indexBy']) || !$mapping['indexBy']) {
1464
+        if ( ! isset($mapping['indexBy']) || ! $mapping['indexBy']) {
1465 1465
             unset($mapping['indexBy']);
1466 1466
         }
1467 1467
 
@@ -1500,7 +1500,7 @@  discard block
 block discarded – undo
1500 1500
                 $this->isIdentifierComposite = true;
1501 1501
             }
1502 1502
 
1503
-            if ($this->cache && !isset($mapping['cache'])) {
1503
+            if ($this->cache && ! isset($mapping['cache'])) {
1504 1504
                 throw CacheException::nonCacheableEntityAssociation($this->name, $mapping['fieldName']);
1505 1505
             }
1506 1506
         }
@@ -1632,7 +1632,7 @@  discard block
 block discarded – undo
1632 1632
                     throw new RuntimeException("ClassMetadataInfo::setTable() has to be called before defining a one to one relationship.");
1633 1633
                 }
1634 1634
 
1635
-                $this->table['uniqueConstraints'][$mapping['fieldName'] . "_uniq"] = array(
1635
+                $this->table['uniqueConstraints'][$mapping['fieldName']."_uniq"] = array(
1636 1636
                     'columns' => $uniqueConstraintColumns
1637 1637
                 );
1638 1638
             }
@@ -1647,7 +1647,7 @@  discard block
 block discarded – undo
1647 1647
             unset($mapping['unique']);
1648 1648
         }
1649 1649
 
1650
-        if (isset($mapping['id']) && $mapping['id'] === true && !$mapping['isOwningSide']) {
1650
+        if (isset($mapping['id']) && $mapping['id'] === true && ! $mapping['isOwningSide']) {
1651 1651
             throw MappingException::illegalInverseIdentifierAssociation($this->name, $mapping['fieldName']);
1652 1652
         }
1653 1653
 
@@ -1705,7 +1705,7 @@  discard block
 block discarded – undo
1705 1705
             }
1706 1706
 
1707 1707
             $selfReferencingEntityWithoutJoinColumns = $mapping['sourceEntity'] == $mapping['targetEntity']
1708
-                && (! (isset($mapping['joinTable']['joinColumns']) || isset($mapping['joinTable']['inverseJoinColumns'])));
1708
+                && ( ! (isset($mapping['joinTable']['joinColumns']) || isset($mapping['joinTable']['inverseJoinColumns'])));
1709 1709
 
1710 1710
             if ( ! isset($mapping['joinTable']['joinColumns'])) {
1711 1711
                 $mapping['joinTable']['joinColumns'] = array(
@@ -1898,7 +1898,7 @@  discard block
 block discarded – undo
1898 1898
 
1899 1899
             // Association defined as Id field
1900 1900
             $joinColumns      = $this->associationMappings[$idProperty]['joinColumns'];
1901
-            $assocColumnNames = array_map(function ($joinColumn) { return $joinColumn['name']; }, $joinColumns);
1901
+            $assocColumnNames = array_map(function($joinColumn) { return $joinColumn['name']; }, $joinColumns);
1902 1902
 
1903 1903
             $columnNames = array_merge($columnNames, $assocColumnNames);
1904 1904
         }
@@ -2079,7 +2079,7 @@  discard block
 block discarded – undo
2079 2079
     public function getTemporaryIdTableName()
2080 2080
     {
2081 2081
         // replace dots with underscores because PostgreSQL creates temporary tables in a special schema
2082
-        return str_replace('.', '_', $this->getTableName() . '_id_tmp');
2082
+        return str_replace('.', '_', $this->getTableName().'_id_tmp');
2083 2083
     }
2084 2084
 
2085 2085
     /**
@@ -2408,7 +2408,7 @@  discard block
 block discarded – undo
2408 2408
      */
2409 2409
     public function addNamedQuery(array $queryMapping)
2410 2410
     {
2411
-        if (!isset($queryMapping['name'])) {
2411
+        if ( ! isset($queryMapping['name'])) {
2412 2412
             throw MappingException::nameIsMandatoryForQueryMapping($this->name);
2413 2413
         }
2414 2414
 
@@ -2416,7 +2416,7 @@  discard block
 block discarded – undo
2416 2416
             throw MappingException::duplicateQueryMapping($this->name, $queryMapping['name']);
2417 2417
         }
2418 2418
 
2419
-        if (!isset($queryMapping['query'])) {
2419
+        if ( ! isset($queryMapping['query'])) {
2420 2420
             throw MappingException::emptyQueryMapping($this->name, $queryMapping['name']);
2421 2421
         }
2422 2422
 
@@ -2443,7 +2443,7 @@  discard block
 block discarded – undo
2443 2443
      */
2444 2444
     public function addNamedNativeQuery(array $queryMapping)
2445 2445
     {
2446
-        if (!isset($queryMapping['name'])) {
2446
+        if ( ! isset($queryMapping['name'])) {
2447 2447
             throw MappingException::nameIsMandatoryForQueryMapping($this->name);
2448 2448
         }
2449 2449
 
@@ -2451,11 +2451,11 @@  discard block
 block discarded – undo
2451 2451
             throw MappingException::duplicateQueryMapping($this->name, $queryMapping['name']);
2452 2452
         }
2453 2453
 
2454
-        if (!isset($queryMapping['query'])) {
2454
+        if ( ! isset($queryMapping['query'])) {
2455 2455
             throw MappingException::emptyQueryMapping($this->name, $queryMapping['name']);
2456 2456
         }
2457 2457
 
2458
-        if (!isset($queryMapping['resultClass']) && !isset($queryMapping['resultSetMapping'])) {
2458
+        if ( ! isset($queryMapping['resultClass']) && ! isset($queryMapping['resultSetMapping'])) {
2459 2459
             throw MappingException::missingQueryMapping($this->name, $queryMapping['name']);
2460 2460
         }
2461 2461
 
@@ -2487,7 +2487,7 @@  discard block
 block discarded – undo
2487 2487
      */
2488 2488
     public function addSqlResultSetMapping(array $resultMapping)
2489 2489
     {
2490
-        if (!isset($resultMapping['name'])) {
2490
+        if ( ! isset($resultMapping['name'])) {
2491 2491
             throw MappingException::nameIsMandatoryForSqlResultSetMapping($this->name);
2492 2492
         }
2493 2493
 
@@ -2497,7 +2497,7 @@  discard block
 block discarded – undo
2497 2497
 
2498 2498
         if (isset($resultMapping['entities'])) {
2499 2499
             foreach ($resultMapping['entities'] as $key => $entityResult) {
2500
-                if (!isset($entityResult['entityClass'])) {
2500
+                if ( ! isset($entityResult['entityClass'])) {
2501 2501
                     throw MappingException::missingResultSetMappingEntity($this->name, $resultMapping['name']);
2502 2502
                 }
2503 2503
 
@@ -2516,11 +2516,11 @@  discard block
 block discarded – undo
2516 2516
 
2517 2517
                 if (isset($entityResult['fields'])) {
2518 2518
                     foreach ($entityResult['fields'] as $k => $field) {
2519
-                        if (!isset($field['name'])) {
2519
+                        if ( ! isset($field['name'])) {
2520 2520
                             throw MappingException::missingResultSetMappingFieldName($this->name, $resultMapping['name']);
2521 2521
                         }
2522 2522
 
2523
-                        if (!isset($field['column'])) {
2523
+                        if ( ! isset($field['column'])) {
2524 2524
                             $fieldName = $field['name'];
2525 2525
                             if (strpos($fieldName, '.')) {
2526 2526
                                 list(, $fieldName) = explode('.', $fieldName);
@@ -3011,7 +3011,7 @@  discard block
 block discarded – undo
3011 3011
         }
3012 3012
 
3013 3013
         if ($definition['sequenceName'][0] == '`') {
3014
-            $definition['sequenceName']   = trim($definition['sequenceName'], '`');
3014
+            $definition['sequenceName'] = trim($definition['sequenceName'], '`');
3015 3015
             $definition['quoted'] = true;
3016 3016
         }
3017 3017
 
@@ -3103,7 +3103,7 @@  discard block
 block discarded – undo
3103 3103
     public function getAssociationTargetClass($assocName)
3104 3104
     {
3105 3105
         if ( ! isset($this->associationMappings[$assocName])) {
3106
-            throw new InvalidArgumentException("Association name expected, '" . $assocName ."' is not an association.");
3106
+            throw new InvalidArgumentException("Association name expected, '".$assocName."' is not an association.");
3107 3107
         }
3108 3108
 
3109 3109
         return $this->associationMappings[$assocName]['targetEntity'];
@@ -3142,7 +3142,7 @@  discard block
 block discarded – undo
3142 3142
             // Association defined as Id field
3143 3143
             $joinColumns            = $this->associationMappings[$idProperty]['joinColumns'];
3144 3144
             $assocQuotedColumnNames = array_map(
3145
-                function ($joinColumn) use ($platform) {
3145
+                function($joinColumn) use ($platform) {
3146 3146
                     return isset($joinColumn['quoted'])
3147 3147
                         ? $platform->quoteIdentifier($joinColumn['name'])
3148 3148
                         : $joinColumn['name'];
@@ -3253,7 +3253,7 @@  discard block
 block discarded – undo
3253 3253
         }
3254 3254
 
3255 3255
         if ($className !== null && strpos($className, '\\') === false && strlen($this->namespace) > 0) {
3256
-            return $this->namespace . '\\' . $className;
3256
+            return $this->namespace.'\\'.$className;
3257 3257
         }
3258 3258
 
3259 3259
         return $className;
@@ -3307,15 +3307,15 @@  discard block
 block discarded – undo
3307 3307
                 ? $fieldMapping['originalClass']
3308 3308
                 : $embeddable->name;
3309 3309
             $fieldMapping['declaredField'] = isset($fieldMapping['declaredField'])
3310
-                ? $property . '.' . $fieldMapping['declaredField']
3310
+                ? $property.'.'.$fieldMapping['declaredField']
3311 3311
                 : $property;
3312 3312
             $fieldMapping['originalField'] = isset($fieldMapping['originalField'])
3313 3313
                 ? $fieldMapping['originalField']
3314 3314
                 : $fieldMapping['fieldName'];
3315
-            $fieldMapping['fieldName'] = $property . "." . $fieldMapping['fieldName'];
3315
+            $fieldMapping['fieldName'] = $property.".".$fieldMapping['fieldName'];
3316 3316
 
3317
-            if (! empty($this->embeddedClasses[$property]['columnPrefix'])) {
3318
-                $fieldMapping['columnName'] = $this->embeddedClasses[$property]['columnPrefix'] . $fieldMapping['columnName'];
3317
+            if ( ! empty($this->embeddedClasses[$property]['columnPrefix'])) {
3318
+                $fieldMapping['columnName'] = $this->embeddedClasses[$property]['columnPrefix'].$fieldMapping['columnName'];
3319 3319
             } elseif ($this->embeddedClasses[$property]['columnPrefix'] !== false) {
3320 3320
                 $fieldMapping['columnName'] = $this->namingStrategy
3321 3321
                     ->embeddedFieldToColumnName(
@@ -3356,7 +3356,7 @@  discard block
 block discarded – undo
3356 3356
     {
3357 3357
         $sequencePrefix = $this->getSequencePrefix($platform);
3358 3358
         $columnName     = $this->getSingleIdentifierColumnName();
3359
-        $sequenceName   = $sequencePrefix . '_' . $columnName . '_seq';
3359
+        $sequenceName   = $sequencePrefix.'_'.$columnName.'_seq';
3360 3360
 
3361 3361
         return $sequenceName;
3362 3362
     }
@@ -3376,10 +3376,10 @@  discard block
 block discarded – undo
3376 3376
 
3377 3377
         // Prepend the schema name to the table name if there is one
3378 3378
         if ($schemaName = $this->getSchemaName()) {
3379
-            $sequencePrefix = $schemaName . '.' . $tableName;
3379
+            $sequencePrefix = $schemaName.'.'.$tableName;
3380 3380
 
3381 3381
             if ( ! $platform->supportsSchemas() && $platform->canEmulateSchemas()) {
3382
-                $sequencePrefix = $schemaName . '__' . $tableName;
3382
+                $sequencePrefix = $schemaName.'__'.$tableName;
3383 3383
             }
3384 3384
         }
3385 3385
 
Please login to merge, or discard this patch.
Doc Comments   +7 added lines, -7 removed lines patch added patch discarded remove patch
@@ -667,7 +667,7 @@  discard block
 block discarded – undo
667 667
     /**
668 668
      * Gets the ReflectionProperties of the mapped class.
669 669
      *
670
-     * @return array An array of ReflectionProperty instances.
670
+     * @return \ReflectionProperty[] An array of ReflectionProperty instances.
671 671
      */
672 672
     public function getReflectionProperties()
673 673
     {
@@ -805,7 +805,7 @@  discard block
 block discarded – undo
805 805
      *      - reflClass (ReflectionClass)
806 806
      *      - reflFields (ReflectionProperty array)
807 807
      *
808
-     * @return array The names of all the fields that should be serialized.
808
+     * @return string[] The names of all the fields that should be serialized.
809 809
      */
810 810
     public function __sleep()
811 811
     {
@@ -1838,7 +1838,7 @@  discard block
 block discarded – undo
1838 1838
      * Sets the mapped identifier/primary key fields of this class.
1839 1839
      * Mainly used by the ClassMetadataFactory to assign inherited identifiers.
1840 1840
      *
1841
-     * @param array $identifier
1841
+     * @param string[] $identifier
1842 1842
      *
1843 1843
      * @return void
1844 1844
      */
@@ -1867,7 +1867,7 @@  discard block
 block discarded – undo
1867 1867
     /**
1868 1868
      * Gets an array containing all the column names.
1869 1869
      *
1870
-     * @param array|null $fieldNames
1870
+     * @param string[] $fieldNames
1871 1871
      *
1872 1872
      * @return array
1873 1873
      */
@@ -2085,7 +2085,7 @@  discard block
 block discarded – undo
2085 2085
     /**
2086 2086
      * Sets the mapped subclasses of this class.
2087 2087
      *
2088
-     * @param array $subclasses The names of all mapped subclasses.
2088
+     * @param string[] $subclasses The names of all mapped subclasses.
2089 2089
      *
2090 2090
      * @return void
2091 2091
      */
@@ -2101,7 +2101,7 @@  discard block
 block discarded – undo
2101 2101
      * Assumes that the class names in the passed array are in the order:
2102 2102
      * directParent -> directParentParent -> directParentParentParent ... -> root.
2103 2103
      *
2104
-     * @param array $classNames
2104
+     * @param string[] $classNames
2105 2105
      *
2106 2106
      * @return void
2107 2107
      */
@@ -2638,7 +2638,7 @@  discard block
 block discarded – undo
2638 2638
      * @deprecated Deprecated since version 2.4 in favor of \Doctrine\ORM\Event\ListenersInvoker
2639 2639
      *
2640 2640
      * @param string $lifecycleEvent The lifecycle event.
2641
-     * @param object $entity         The Entity on which the event occurred.
2641
+     * @param \Doctrine\Tests\ORM\Functional\Ticket\DDC1707Child $entity         The Entity on which the event occurred.
2642 2642
      *
2643 2643
      * @return void
2644 2644
      */
Please login to merge, or discard this patch.
lib/Doctrine/ORM/Mapping/Builder/FieldBuilder.php 2 patches
Spacing   +1 added lines, -1 removed lines patch added patch discarded remove patch
@@ -275,7 +275,7 @@
 block discarded – undo
275 275
     {
276 276
         $cm = $this->builder->getClassMetadata();
277 277
         if ($this->generatedValue) {
278
-            $cm->setIdGeneratorType(constant('Doctrine\ORM\Mapping\ClassMetadata::GENERATOR_TYPE_' . $this->generatedValue));
278
+            $cm->setIdGeneratorType(constant('Doctrine\ORM\Mapping\ClassMetadata::GENERATOR_TYPE_'.$this->generatedValue));
279 279
         }
280 280
 
281 281
         if ($this->version) {
Please login to merge, or discard this patch.
Doc Comments   +1 added lines, -1 removed lines patch added patch discarded remove patch
@@ -180,7 +180,7 @@
 block discarded – undo
180 180
      * Sets an option.
181 181
      *
182 182
      * @param string $name
183
-     * @param mixed  $value
183
+     * @param boolean  $value
184 184
      *
185 185
      * @return FieldBuilder
186 186
      */
Please login to merge, or discard this patch.
lib/Doctrine/ORM/Mapping/Builder/ClassMetadataBuilder.php 2 patches
Spacing   +1 added lines, -1 removed lines patch added patch discarded remove patch
@@ -150,7 +150,7 @@
 block discarded – undo
150 150
      */
151 151
     public function addIndex(array $columns, $name)
152 152
     {
153
-        if (!isset($this->cm->table['indexes'])) {
153
+        if ( ! isset($this->cm->table['indexes'])) {
154 154
             $this->cm->table['indexes'] = array();
155 155
         }
156 156
 
Please login to merge, or discard this patch.
Doc Comments   +2 added lines, -2 removed lines patch added patch discarded remove patch
@@ -143,7 +143,7 @@  discard block
 block discarded – undo
143 143
     /**
144 144
      * Adds Index.
145 145
      *
146
-     * @param array  $columns
146
+     * @param string[]  $columns
147 147
      * @param string $name
148 148
      *
149 149
      * @return ClassMetadataBuilder
@@ -162,7 +162,7 @@  discard block
 block discarded – undo
162 162
     /**
163 163
      * Adds Unique Constraint.
164 164
      *
165
-     * @param array  $columns
165
+     * @param string[]  $columns
166 166
      * @param string $name
167 167
      *
168 168
      * @return ClassMetadataBuilder
Please login to merge, or discard this patch.
lib/Doctrine/ORM/Mapping/ClassMetadataFactory.php 1 patch
Spacing   +13 added lines, -13 removed lines patch added patch discarded remove patch
@@ -105,7 +105,7 @@  discard block
 block discarded – undo
105 105
      */
106 106
     protected function onNotFoundMetadata($className)
107 107
     {
108
-        if (! $this->evm->hasListeners(Events::onClassMetadataNotFound)) {
108
+        if ( ! $this->evm->hasListeners(Events::onClassMetadataNotFound)) {
109 109
             return;
110 110
         }
111 111
 
@@ -162,7 +162,7 @@  discard block
 block discarded – undo
162 162
             $this->completeIdGeneratorMapping($class);
163 163
         }
164 164
 
165
-        if (!$class->isMappedSuperclass) {
165
+        if ( ! $class->isMappedSuperclass) {
166 166
             foreach ($class->embeddedClasses as $property => $embeddableClass) {
167 167
 
168 168
                 if (isset($embeddableClass['inherited'])) {
@@ -187,7 +187,7 @@  discard block
 block discarded – undo
187 187
 
188 188
                 $identifier = $embeddableMetadata->getIdentifier();
189 189
 
190
-                if (! empty($identifier)) {
190
+                if ( ! empty($identifier)) {
191 191
                     $this->inheritIdGeneratorMapping($class, $embeddableMetadata);
192 192
                 }
193 193
 
@@ -257,7 +257,7 @@  discard block
 block discarded – undo
257 257
      */
258 258
     protected function validateRuntimeMetadata($class, $parent)
259 259
     {
260
-        if ( ! $class->reflClass ) {
260
+        if ( ! $class->reflClass) {
261 261
             // only validate if there is a reflection class instance
262 262
             return;
263 263
         }
@@ -267,7 +267,7 @@  discard block
 block discarded – undo
267 267
         $class->validateLifecycleCallbacks($this->getReflectionService());
268 268
 
269 269
         // verify inheritance
270
-        if ( ! $class->isMappedSuperclass && !$class->isInheritanceTypeNone()) {
270
+        if ( ! $class->isMappedSuperclass && ! $class->isInheritanceTypeNone()) {
271 271
             if ( ! $parent) {
272 272
                 if (count($class->discriminatorMap) == 0) {
273 273
                     throw MappingException::missingDiscriminatorMap($class->name);
@@ -428,7 +428,7 @@  discard block
 block discarded – undo
428 428
     {
429 429
         foreach ($parentClass->associationMappings as $field => $mapping) {
430 430
             if ($parentClass->isMappedSuperclass) {
431
-                if ($mapping['type'] & ClassMetadata::TO_MANY && !$mapping['isOwningSide']) {
431
+                if ($mapping['type'] & ClassMetadata::TO_MANY && ! $mapping['isOwningSide']) {
432 432
                     throw MappingException::illegalToManyAssociationOnMappedSuperclass($parentClass->name, $field);
433 433
                 }
434 434
                 $mapping['sourceEntity'] = $subClass->name;
@@ -476,11 +476,11 @@  discard block
 block discarded – undo
476 476
             $embeddableMetadata = $this->getMetadataFor($embeddableClass['class']);
477 477
 
478 478
             $parentClass->mapEmbedded(array(
479
-                'fieldName' => $prefix . '.' . $property,
479
+                'fieldName' => $prefix.'.'.$property,
480 480
                 'class' => $embeddableMetadata->name,
481 481
                 'columnPrefix' => $embeddableClass['columnPrefix'],
482 482
                 'declaredField' => $embeddableClass['declaredField']
483
-                        ? $prefix . '.' . $embeddableClass['declaredField']
483
+                        ? $prefix.'.'.$embeddableClass['declaredField']
484 484
                         : $prefix,
485 485
                 'originalField' => $embeddableClass['originalField'] ?: $property,
486 486
             ));
@@ -497,7 +497,7 @@  discard block
 block discarded – undo
497 497
      */
498 498
     private function addInheritedIndexes(ClassMetadata $subClass, ClassMetadata $parentClass)
499 499
     {
500
-        if (! $parentClass->isMappedSuperclass) {
500
+        if ( ! $parentClass->isMappedSuperclass) {
501 501
             return;
502 502
         }
503 503
 
@@ -696,14 +696,14 @@  discard block
 block discarded – undo
696 696
             case ClassMetadata::GENERATOR_TYPE_CUSTOM:
697 697
                 $definition = $class->customGeneratorDefinition;
698 698
                 if ( ! class_exists($definition['class'])) {
699
-                    throw new ORMException("Can't instantiate custom generator : " .
699
+                    throw new ORMException("Can't instantiate custom generator : ".
700 700
                         $definition['class']);
701 701
                 }
702 702
                 $class->setIdGenerator(new $definition['class']);
703 703
                 break;
704 704
 
705 705
             default:
706
-                throw new ORMException("Unknown generator type: " . $class->generatorType);
706
+                throw new ORMException("Unknown generator type: ".$class->generatorType);
707 707
         }
708 708
     }
709 709
 
@@ -753,7 +753,7 @@  discard block
 block discarded – undo
753 753
      */
754 754
     protected function getFqcnFromAlias($namespaceAlias, $simpleClassName)
755 755
     {
756
-        return $this->em->getConfiguration()->getEntityNamespace($namespaceAlias) . '\\' . $simpleClassName;
756
+        return $this->em->getConfiguration()->getEntityNamespace($namespaceAlias).'\\'.$simpleClassName;
757 757
     }
758 758
 
759 759
     /**
@@ -777,7 +777,7 @@  discard block
 block discarded – undo
777 777
      */
778 778
     private function getTargetPlatform()
779 779
     {
780
-        if (!$this->targetPlatform) {
780
+        if ( ! $this->targetPlatform) {
781 781
             $this->targetPlatform = $this->em->getConnection()->getDatabasePlatform();
782 782
         }
783 783
 
Please login to merge, or discard this patch.
lib/Doctrine/ORM/Mapping/DefaultEntityListenerResolver.php 1 patch
Indentation   +1 added lines, -1 removed lines patch added patch discarded remove patch
@@ -67,7 +67,7 @@
 block discarded – undo
67 67
     public function resolve($className)
68 68
     {
69 69
         if (isset($this->instances[$className = trim($className, '\\')])) {
70
-           return $this->instances[$className];
70
+            return $this->instances[$className];
71 71
         }
72 72
 
73 73
         return $this->instances[$className] = new $className();
Please login to merge, or discard this patch.
lib/Doctrine/ORM/Internal/Hydration/SimpleObjectHydrator.php 1 patch
Unused Use Statements   -1 removed lines patch added patch discarded remove patch
@@ -19,7 +19,6 @@
 block discarded – undo
19 19
 
20 20
 namespace Doctrine\ORM\Query;
21 21
 
22
-use Doctrine\DBAL\Types\Type;
23 22
 use Doctrine\ORM\EntityManagerInterface;
24 23
 use Doctrine\ORM\Mapping\ClassMetadataInfo;
25 24
 use Doctrine\ORM\Mapping\MappingException;
Please login to merge, or discard this patch.
lib/Doctrine/ORM/Cache/Persister/Collection/AbstractCollectionPersister.php 1 patch
Indentation   +6 added lines, -6 removed lines patch added patch discarded remove patch
@@ -41,9 +41,9 @@  discard block
 block discarded – undo
41 41
  */
42 42
 abstract class AbstractEntityPersister implements CachedEntityPersister
43 43
 {
44
-     /**
45
-     * @var \Doctrine\ORM\UnitOfWork
46
-     */
44
+        /**
45
+         * @var \Doctrine\ORM\UnitOfWork
46
+         */
47 47
     protected $uow;
48 48
 
49 49
     /**
@@ -61,9 +61,9 @@  discard block
 block discarded – undo
61 61
      */
62 62
     protected $class;
63 63
 
64
-     /**
65
-     * @var array
66
-     */
64
+        /**
65
+         * @var array
66
+         */
67 67
     protected $queuedCache = array();
68 68
 
69 69
     /**
Please login to merge, or discard this patch.