Code Duplication    Length = 3-3 lines in 4 locations

lib/Doctrine/ORM/Mapping/ClassMetadataInfo.php 4 locations

@@ 1428-1430 (lines=3) @@
1425
        }
1426
1427
        if (Type::hasType($mapping['type']) && Type::getType($mapping['type'])->canRequireSQLConversion()) {
1428
            if (isset($mapping['id']) && true === $mapping['id']) {
1429
                 throw MappingException::sqlConversionNotAllowedForIdentifiers($this->name, $mapping['fieldName'], $mapping['type']);
1430
            }
1431
1432
            $mapping['requireSQLConversion'] = true;
1433
        }
@@ 1471-1473 (lines=3) @@
1468
            $mapping['targetEntity'] = ltrim($mapping['targetEntity'], '\\');
1469
        }
1470
1471
        if (($mapping['type'] & self::MANY_TO_ONE) > 0 && isset($mapping['orphanRemoval']) && $mapping['orphanRemoval']) {
1472
            throw MappingException::illegalOrphanRemoval($this->name, $mapping['fieldName']);
1473
        }
1474
1475
        // Complete id mapping
1476
        if (isset($mapping['id']) && true === $mapping['id']) {
@@ 1524-1526 (lines=3) @@
1521
            $mapping['isOwningSide'] = false;
1522
        }
1523
1524
        if (isset($mapping['id']) && true === $mapping['id'] && $mapping['type'] & self::TO_MANY) {
1525
            throw MappingException::illegalToManyIdentifierAssociation($this->name, $mapping['fieldName']);
1526
        }
1527
1528
        // Fetch mode. Default fetch mode to LAZY, if not set.
1529
        if ( ! isset($mapping['fetch'])) {
@@ 1641-1643 (lines=3) @@
1638
            unset($mapping['unique']);
1639
        }
1640
1641
        if (isset($mapping['id']) && $mapping['id'] === true && !$mapping['isOwningSide']) {
1642
            throw MappingException::illegalInverseIdentifierAssociation($this->name, $mapping['fieldName']);
1643
        }
1644
1645
        return $mapping;
1646
    }