@@ -346,9 +346,9 @@ discard block |
||
346 | 346 | $columnName = $this->quoteStrategy->getColumnName($versionField, $versionedClass, $this->platform); |
347 | 347 | |
348 | 348 | // FIXME: Order with composite keys might not be correct |
349 | - $sql = 'SELECT ' . $columnName |
|
350 | - . ' FROM ' . $tableName |
|
351 | - . ' WHERE ' . implode(' = ? AND ', $identifier) . ' = ?'; |
|
349 | + $sql = 'SELECT '.$columnName |
|
350 | + . ' FROM '.$tableName |
|
351 | + . ' WHERE '.implode(' = ? AND ', $identifier).' = ?'; |
|
352 | 352 | |
353 | 353 | |
354 | 354 | $flatId = $this->identifierFlattener->flattenIdentifier($versionedClass, $id); |
@@ -441,7 +441,7 @@ discard block |
||
441 | 441 | } |
442 | 442 | |
443 | 443 | $params[] = $value; |
444 | - $set[] = $column . ' = ' . $placeholder; |
|
444 | + $set[] = $column.' = '.$placeholder; |
|
445 | 445 | $types[] = $this->columnTypes[$columnName]; |
446 | 446 | } |
447 | 447 | |
@@ -487,18 +487,18 @@ discard block |
||
487 | 487 | case Type::SMALLINT: |
488 | 488 | case Type::INTEGER: |
489 | 489 | case Type::BIGINT: |
490 | - $set[] = $versionColumn . ' = ' . $versionColumn . ' + 1'; |
|
490 | + $set[] = $versionColumn.' = '.$versionColumn.' + 1'; |
|
491 | 491 | break; |
492 | 492 | |
493 | 493 | case Type::DATETIME: |
494 | - $set[] = $versionColumn . ' = CURRENT_TIMESTAMP'; |
|
494 | + $set[] = $versionColumn.' = CURRENT_TIMESTAMP'; |
|
495 | 495 | break; |
496 | 496 | } |
497 | 497 | } |
498 | 498 | |
499 | - $sql = 'UPDATE ' . $quotedTableName |
|
500 | - . ' SET ' . implode(', ', $set) |
|
501 | - . ' WHERE ' . implode(' = ? AND ', $where) . ' = ?'; |
|
499 | + $sql = 'UPDATE '.$quotedTableName |
|
500 | + . ' SET '.implode(', ', $set) |
|
501 | + . ' WHERE '.implode(' = ? AND ', $where).' = ?'; |
|
502 | 502 | |
503 | 503 | $result = $this->conn->executeUpdate($sql, $params, $types); |
504 | 504 | |
@@ -541,7 +541,7 @@ discard block |
||
541 | 541 | |
542 | 542 | |
543 | 543 | if ($selfReferential) { |
544 | - $otherColumns = (! $mapping['isOwningSide']) |
|
544 | + $otherColumns = ( ! $mapping['isOwningSide']) |
|
545 | 545 | ? $association['joinTable']['joinColumns'] |
546 | 546 | : $association['joinTable']['inverseJoinColumns']; |
547 | 547 | } |
@@ -690,7 +690,7 @@ discard block |
||
690 | 690 | } |
691 | 691 | $oid = spl_object_hash($newVal); |
692 | 692 | $uow = $this->em->getUnitOfWork(); |
693 | - if (!(isset($this->queuedInserts[$oid]) || $uow->isScheduledForInsert($newVal))) { |
|
693 | + if ( ! (isset($this->queuedInserts[$oid]) || $uow->isScheduledForInsert($newVal))) { |
|
694 | 694 | return false; |
695 | 695 | } |
696 | 696 | if ($newVal !== $entity) { |
@@ -1046,7 +1046,7 @@ discard block |
||
1046 | 1046 | ); |
1047 | 1047 | } |
1048 | 1048 | |
1049 | - $criteria[$quotedJoinTable . '.' . $quotedKeyColumn] = $value; |
|
1049 | + $criteria[$quotedJoinTable.'.'.$quotedKeyColumn] = $value; |
|
1050 | 1050 | $parameters[] = [ |
1051 | 1051 | 'value' => $value, |
1052 | 1052 | 'field' => $field, |
@@ -1089,11 +1089,11 @@ discard block |
||
1089 | 1089 | |
1090 | 1090 | switch ($lockMode) { |
1091 | 1091 | case LockMode::PESSIMISTIC_READ: |
1092 | - $lockSql = ' ' . $this->platform->getReadLockSQL(); |
|
1092 | + $lockSql = ' '.$this->platform->getReadLockSQL(); |
|
1093 | 1093 | break; |
1094 | 1094 | |
1095 | 1095 | case LockMode::PESSIMISTIC_WRITE: |
1096 | - $lockSql = ' ' . $this->platform->getWriteLockSQL(); |
|
1096 | + $lockSql = ' '.$this->platform->getWriteLockSQL(); |
|
1097 | 1097 | break; |
1098 | 1098 | } |
1099 | 1099 | |
@@ -1104,14 +1104,14 @@ discard block |
||
1104 | 1104 | |
1105 | 1105 | if ('' !== $filterSql) { |
1106 | 1106 | $conditionSql = $conditionSql |
1107 | - ? $conditionSql . ' AND ' . $filterSql |
|
1107 | + ? $conditionSql.' AND '.$filterSql |
|
1108 | 1108 | : $filterSql; |
1109 | 1109 | } |
1110 | 1110 | |
1111 | - $select = 'SELECT ' . $columnList; |
|
1112 | - $from = ' FROM ' . $tableName . ' '. $tableAlias; |
|
1113 | - $join = $this->currentPersisterContext->selectJoinSql . $joinSql; |
|
1114 | - $where = ($conditionSql ? ' WHERE ' . $conditionSql : ''); |
|
1111 | + $select = 'SELECT '.$columnList; |
|
1112 | + $from = ' FROM '.$tableName.' '.$tableAlias; |
|
1113 | + $join = $this->currentPersisterContext->selectJoinSql.$joinSql; |
|
1114 | + $where = ($conditionSql ? ' WHERE '.$conditionSql : ''); |
|
1115 | 1115 | $lock = $this->platform->appendLockHint($from, $lockMode); |
1116 | 1116 | $query = $select |
1117 | 1117 | . $lock |
@@ -1119,7 +1119,7 @@ discard block |
||
1119 | 1119 | . $where |
1120 | 1120 | . $orderBySql; |
1121 | 1121 | |
1122 | - return $this->platform->modifyLimitQuery($query, $limit, $offset) . $lockSql; |
|
1122 | + return $this->platform->modifyLimitQuery($query, $limit, $offset).$lockSql; |
|
1123 | 1123 | } |
1124 | 1124 | |
1125 | 1125 | /** |
@@ -1138,13 +1138,13 @@ discard block |
||
1138 | 1138 | |
1139 | 1139 | if ('' !== $filterSql) { |
1140 | 1140 | $conditionSql = $conditionSql |
1141 | - ? $conditionSql . ' AND ' . $filterSql |
|
1141 | + ? $conditionSql.' AND '.$filterSql |
|
1142 | 1142 | : $filterSql; |
1143 | 1143 | } |
1144 | 1144 | |
1145 | 1145 | $sql = 'SELECT COUNT(*) ' |
1146 | - . 'FROM ' . $tableName . ' ' . $tableAlias |
|
1147 | - . (empty($conditionSql) ? '' : ' WHERE ' . $conditionSql); |
|
1146 | + . 'FROM '.$tableName.' '.$tableAlias |
|
1147 | + . (empty($conditionSql) ? '' : ' WHERE '.$conditionSql); |
|
1148 | 1148 | |
1149 | 1149 | return $sql; |
1150 | 1150 | } |
@@ -1177,7 +1177,7 @@ discard block |
||
1177 | 1177 | : $baseTableAlias; |
1178 | 1178 | |
1179 | 1179 | $columnName = $this->quoteStrategy->getColumnName($fieldName, $this->class, $this->platform); |
1180 | - $orderByList[] = $tableAlias . '.' . $columnName . ' ' . $orientation; |
|
1180 | + $orderByList[] = $tableAlias.'.'.$columnName.' '.$orientation; |
|
1181 | 1181 | |
1182 | 1182 | continue; |
1183 | 1183 | } |
@@ -1194,7 +1194,7 @@ discard block |
||
1194 | 1194 | |
1195 | 1195 | foreach ($this->class->associationMappings[$fieldName]['joinColumns'] as $joinColumn) { |
1196 | 1196 | $columnName = $this->quoteStrategy->getJoinColumnName($joinColumn, $this->class, $this->platform); |
1197 | - $orderByList[] = $tableAlias . '.' . $columnName . ' ' . $orientation; |
|
1197 | + $orderByList[] = $tableAlias.'.'.$columnName.' '.$orientation; |
|
1198 | 1198 | } |
1199 | 1199 | |
1200 | 1200 | continue; |
@@ -1203,7 +1203,7 @@ discard block |
||
1203 | 1203 | throw ORMException::unrecognizedField($fieldName); |
1204 | 1204 | } |
1205 | 1205 | |
1206 | - return ' ORDER BY ' . implode(', ', $orderByList); |
|
1206 | + return ' ORDER BY '.implode(', ', $orderByList); |
|
1207 | 1207 | } |
1208 | 1208 | |
1209 | 1209 | /** |
@@ -1231,8 +1231,8 @@ discard block |
||
1231 | 1231 | $columnList[] = $this->getSelectColumnSQL($field, $this->class); |
1232 | 1232 | } |
1233 | 1233 | |
1234 | - $this->currentPersisterContext->selectJoinSql = ''; |
|
1235 | - $eagerAliasCounter = 0; |
|
1234 | + $this->currentPersisterContext->selectJoinSql = ''; |
|
1235 | + $eagerAliasCounter = 0; |
|
1236 | 1236 | |
1237 | 1237 | foreach ($this->class->associationMappings as $assocField => $assoc) { |
1238 | 1238 | $assocColumnSQL = $this->getSelectColumnAssociationSQL($assocField, $assoc, $this->class); |
@@ -1258,7 +1258,7 @@ discard block |
||
1258 | 1258 | continue; // now this is why you shouldn't use inheritance |
1259 | 1259 | } |
1260 | 1260 | |
1261 | - $assocAlias = 'e' . ($eagerAliasCounter++); |
|
1261 | + $assocAlias = 'e'.($eagerAliasCounter++); |
|
1262 | 1262 | $this->currentPersisterContext->rsm->addJoinedEntityResult($assoc['targetEntity'], $assocAlias, 'r', $assocField); |
1263 | 1263 | |
1264 | 1264 | foreach ($eagerEntity->fieldNames as $field) { |
@@ -1291,14 +1291,14 @@ discard block |
||
1291 | 1291 | $joinTableName = $this->quoteStrategy->getTableName($eagerEntity, $this->platform); |
1292 | 1292 | |
1293 | 1293 | if ($assoc['isOwningSide']) { |
1294 | - $tableAlias = $this->getSQLTableAlias($association['targetEntity'], $assocAlias); |
|
1295 | - $this->currentPersisterContext->selectJoinSql .= ' ' . $this->getJoinSQLForJoinColumns($association['joinColumns']); |
|
1294 | + $tableAlias = $this->getSQLTableAlias($association['targetEntity'], $assocAlias); |
|
1295 | + $this->currentPersisterContext->selectJoinSql .= ' '.$this->getJoinSQLForJoinColumns($association['joinColumns']); |
|
1296 | 1296 | |
1297 | 1297 | foreach ($association['joinColumns'] as $joinColumn) { |
1298 | 1298 | $sourceCol = $this->quoteStrategy->getJoinColumnName($joinColumn, $this->class, $this->platform); |
1299 | 1299 | $targetCol = $this->quoteStrategy->getReferencedJoinColumnName($joinColumn, $this->class, $this->platform); |
1300 | 1300 | $joinCondition[] = $this->getSQLTableAlias($association['sourceEntity']) |
1301 | - . '.' . $sourceCol . ' = ' . $tableAlias . '.' . $targetCol; |
|
1301 | + . '.'.$sourceCol.' = '.$tableAlias.'.'.$targetCol; |
|
1302 | 1302 | } |
1303 | 1303 | |
1304 | 1304 | // Add filter SQL |
@@ -1314,12 +1314,12 @@ discard block |
||
1314 | 1314 | $sourceCol = $this->quoteStrategy->getJoinColumnName($joinColumn, $this->class, $this->platform); |
1315 | 1315 | $targetCol = $this->quoteStrategy->getReferencedJoinColumnName($joinColumn, $this->class, $this->platform); |
1316 | 1316 | |
1317 | - $joinCondition[] = $this->getSQLTableAlias($association['sourceEntity'], $assocAlias) . '.' . $sourceCol . ' = ' |
|
1318 | - . $this->getSQLTableAlias($association['targetEntity']) . '.' . $targetCol; |
|
1317 | + $joinCondition[] = $this->getSQLTableAlias($association['sourceEntity'], $assocAlias).'.'.$sourceCol.' = ' |
|
1318 | + . $this->getSQLTableAlias($association['targetEntity']).'.'.$targetCol; |
|
1319 | 1319 | } |
1320 | 1320 | } |
1321 | 1321 | |
1322 | - $this->currentPersisterContext->selectJoinSql .= ' ' . $joinTableName . ' ' . $joinTableAlias . ' ON '; |
|
1322 | + $this->currentPersisterContext->selectJoinSql .= ' '.$joinTableName.' '.$joinTableAlias.' ON '; |
|
1323 | 1323 | $this->currentPersisterContext->selectJoinSql .= implode(' AND ', $joinCondition); |
1324 | 1324 | } |
1325 | 1325 | |
@@ -1340,7 +1340,7 @@ discard block |
||
1340 | 1340 | */ |
1341 | 1341 | protected function getSelectColumnAssociationSQL($field, $assoc, ClassMetadata $class, $alias = 'r') |
1342 | 1342 | { |
1343 | - if ( ! ($assoc['isOwningSide'] && $assoc['type'] & ClassMetadata::TO_ONE) ) { |
|
1343 | + if ( ! ($assoc['isOwningSide'] && $assoc['type'] & ClassMetadata::TO_ONE)) { |
|
1344 | 1344 | return ''; |
1345 | 1345 | } |
1346 | 1346 | |
@@ -1389,10 +1389,10 @@ discard block |
||
1389 | 1389 | foreach ($joinColumns as $joinColumn) { |
1390 | 1390 | $quotedSourceColumn = $this->quoteStrategy->getJoinColumnName($joinColumn, $this->class, $this->platform); |
1391 | 1391 | $quotedTargetColumn = $this->quoteStrategy->getReferencedJoinColumnName($joinColumn, $this->class, $this->platform); |
1392 | - $conditions[] = $sourceTableAlias . '.' . $quotedTargetColumn . ' = ' . $joinTableName . '.' . $quotedSourceColumn; |
|
1392 | + $conditions[] = $sourceTableAlias.'.'.$quotedTargetColumn.' = '.$joinTableName.'.'.$quotedSourceColumn; |
|
1393 | 1393 | } |
1394 | 1394 | |
1395 | - return ' INNER JOIN ' . $joinTableName . ' ON ' . implode(' AND ', $conditions); |
|
1395 | + return ' INNER JOIN '.$joinTableName.' ON '.implode(' AND ', $conditions); |
|
1396 | 1396 | } |
1397 | 1397 | |
1398 | 1398 | /** |
@@ -1471,7 +1471,7 @@ discard block |
||
1471 | 1471 | continue; |
1472 | 1472 | } |
1473 | 1473 | |
1474 | - if (! $this->class->isIdGeneratorIdentity() || $this->class->identifier[0] != $name) { |
|
1474 | + if ( ! $this->class->isIdGeneratorIdentity() || $this->class->identifier[0] != $name) { |
|
1475 | 1475 | $columns[] = $this->quoteStrategy->getColumnName($name, $this->class, $this->platform); |
1476 | 1476 | $this->columnTypes[$name] = $this->class->fieldMappings[$name]['type']; |
1477 | 1477 | } |
@@ -1492,7 +1492,7 @@ discard block |
||
1492 | 1492 | */ |
1493 | 1493 | protected function getSelectColumnSQL($field, ClassMetadata $class, $alias = 'r') |
1494 | 1494 | { |
1495 | - $root = $alias == 'r' ? '' : $alias ; |
|
1495 | + $root = $alias == 'r' ? '' : $alias; |
|
1496 | 1496 | $tableAlias = $this->getSQLTableAlias($class->name, $root); |
1497 | 1497 | $fieldMapping = $class->fieldMappings[$field]; |
1498 | 1498 | $sql = sprintf('%s.%s', $tableAlias, $this->quoteStrategy->getColumnName($field, $class, $this->platform)); |
@@ -1505,7 +1505,7 @@ discard block |
||
1505 | 1505 | $sql = $type->convertToPHPValueSQL($sql, $this->platform); |
1506 | 1506 | } |
1507 | 1507 | |
1508 | - return $sql . ' AS ' . $columnAlias; |
|
1508 | + return $sql.' AS '.$columnAlias; |
|
1509 | 1509 | } |
1510 | 1510 | |
1511 | 1511 | /** |
@@ -1521,14 +1521,14 @@ discard block |
||
1521 | 1521 | protected function getSQLTableAlias($className, $assocName = '') |
1522 | 1522 | { |
1523 | 1523 | if ($assocName) { |
1524 | - $className .= '#' . $assocName; |
|
1524 | + $className .= '#'.$assocName; |
|
1525 | 1525 | } |
1526 | 1526 | |
1527 | 1527 | if (isset($this->currentPersisterContext->sqlTableAliases[$className])) { |
1528 | 1528 | return $this->currentPersisterContext->sqlTableAliases[$className]; |
1529 | 1529 | } |
1530 | 1530 | |
1531 | - $tableAlias = 't' . $this->currentPersisterContext->sqlAliasCounter++; |
|
1531 | + $tableAlias = 't'.$this->currentPersisterContext->sqlAliasCounter++; |
|
1532 | 1532 | |
1533 | 1533 | $this->currentPersisterContext->sqlTableAliases[$className] = $tableAlias; |
1534 | 1534 | |
@@ -1555,7 +1555,7 @@ discard block |
||
1555 | 1555 | } |
1556 | 1556 | |
1557 | 1557 | $lock = $this->getLockTablesSql($lockMode); |
1558 | - $where = ($conditionSql ? ' WHERE ' . $conditionSql : '') . ' '; |
|
1558 | + $where = ($conditionSql ? ' WHERE '.$conditionSql : '').' '; |
|
1559 | 1559 | $sql = 'SELECT 1 ' |
1560 | 1560 | . $lock |
1561 | 1561 | . $where |
@@ -1577,7 +1577,7 @@ discard block |
||
1577 | 1577 | { |
1578 | 1578 | return $this->platform->appendLockHint( |
1579 | 1579 | 'FROM ' |
1580 | - . $this->quoteStrategy->getTableName($this->class, $this->platform) . ' ' |
|
1580 | + . $this->quoteStrategy->getTableName($this->class, $this->platform).' ' |
|
1581 | 1581 | . $this->getSQLTableAlias($this->class->name), |
1582 | 1582 | $lockMode |
1583 | 1583 | ); |
@@ -1629,19 +1629,19 @@ discard block |
||
1629 | 1629 | |
1630 | 1630 | if (null !== $comparison) { |
1631 | 1631 | // special case null value handling |
1632 | - if (($comparison === Comparison::EQ || $comparison === Comparison::IS) && null ===$value) { |
|
1633 | - $selectedColumns[] = $column . ' IS NULL'; |
|
1632 | + if (($comparison === Comparison::EQ || $comparison === Comparison::IS) && null === $value) { |
|
1633 | + $selectedColumns[] = $column.' IS NULL'; |
|
1634 | 1634 | |
1635 | 1635 | continue; |
1636 | 1636 | } |
1637 | 1637 | |
1638 | 1638 | if ($comparison === Comparison::NEQ && null === $value) { |
1639 | - $selectedColumns[] = $column . ' IS NOT NULL'; |
|
1639 | + $selectedColumns[] = $column.' IS NOT NULL'; |
|
1640 | 1640 | |
1641 | 1641 | continue; |
1642 | 1642 | } |
1643 | 1643 | |
1644 | - $selectedColumns[] = $column . ' ' . sprintf(self::$comparisonMap[$comparison], $placeholder); |
|
1644 | + $selectedColumns[] = $column.' '.sprintf(self::$comparisonMap[$comparison], $placeholder); |
|
1645 | 1645 | |
1646 | 1646 | continue; |
1647 | 1647 | } |
@@ -1689,7 +1689,7 @@ discard block |
||
1689 | 1689 | ? $this->class->fieldMappings[$field]['inherited'] |
1690 | 1690 | : $this->class->name; |
1691 | 1691 | |
1692 | - return [$this->getSQLTableAlias($className) . '.' . $this->quoteStrategy->getColumnName($field, $this->class, $this->platform)]; |
|
1692 | + return [$this->getSQLTableAlias($className).'.'.$this->quoteStrategy->getColumnName($field, $this->class, $this->platform)]; |
|
1693 | 1693 | } |
1694 | 1694 | |
1695 | 1695 | if (isset($this->class->associationMappings[$field])) { |
@@ -1710,7 +1710,7 @@ discard block |
||
1710 | 1710 | |
1711 | 1711 | |
1712 | 1712 | foreach ($joinColumns as $joinColumn) { |
1713 | - $columns[] = $joinTableName . '.' . $this->quoteStrategy->getJoinColumnName($joinColumn, $class, $this->platform); |
|
1713 | + $columns[] = $joinTableName.'.'.$this->quoteStrategy->getJoinColumnName($joinColumn, $class, $this->platform); |
|
1714 | 1714 | } |
1715 | 1715 | |
1716 | 1716 | } else { |
@@ -1718,12 +1718,12 @@ discard block |
||
1718 | 1718 | throw ORMException::invalidFindByInverseAssociation($this->class->name, $field); |
1719 | 1719 | } |
1720 | 1720 | |
1721 | - $className = (isset($association['inherited'])) |
|
1721 | + $className = (isset($association['inherited'])) |
|
1722 | 1722 | ? $association['inherited'] |
1723 | 1723 | : $this->class->name; |
1724 | 1724 | |
1725 | 1725 | foreach ($association['joinColumns'] as $joinColumn) { |
1726 | - $columns[] = $this->getSQLTableAlias($className) . '.' . $this->quoteStrategy->getJoinColumnName($joinColumn, $this->class, $this->platform); |
|
1726 | + $columns[] = $this->getSQLTableAlias($className).'.'.$this->quoteStrategy->getJoinColumnName($joinColumn, $this->class, $this->platform); |
|
1727 | 1727 | } |
1728 | 1728 | } |
1729 | 1729 | return $columns; |
@@ -1815,7 +1815,7 @@ discard block |
||
1815 | 1815 | $value = $value[$this->em->getClassMetadata($sourceClass->associationMappings[$field]['targetEntity'])->identifier[0]]; |
1816 | 1816 | } |
1817 | 1817 | |
1818 | - $criteria[$tableAlias . "." . $targetKeyColumn] = $value; |
|
1818 | + $criteria[$tableAlias.".".$targetKeyColumn] = $value; |
|
1819 | 1819 | $parameters[] = [ |
1820 | 1820 | 'value' => $value, |
1821 | 1821 | 'field' => $field, |
@@ -1828,7 +1828,7 @@ discard block |
||
1828 | 1828 | $field = $sourceClass->fieldNames[$sourceKeyColumn]; |
1829 | 1829 | $value = $sourceClass->reflFields[$field]->getValue($sourceEntity); |
1830 | 1830 | |
1831 | - $criteria[$tableAlias . "." . $targetKeyColumn] = $value; |
|
1831 | + $criteria[$tableAlias.".".$targetKeyColumn] = $value; |
|
1832 | 1832 | $parameters[] = [ |
1833 | 1833 | 'value' => $value, |
1834 | 1834 | 'field' => $field, |
@@ -1916,7 +1916,7 @@ discard block |
||
1916 | 1916 | $assoc = $class->associationMappings[$field]; |
1917 | 1917 | $class = $this->em->getClassMetadata($assoc['targetEntity']); |
1918 | 1918 | |
1919 | - if (! $assoc['isOwningSide']) { |
|
1919 | + if ( ! $assoc['isOwningSide']) { |
|
1920 | 1920 | $assoc = $class->associationMappings[$assoc['mappedBy']]; |
1921 | 1921 | $class = $this->em->getClassMetadata($assoc['targetEntity']); |
1922 | 1922 | } |
@@ -1925,7 +1925,7 @@ discard block |
||
1925 | 1925 | ? $assoc['relationToTargetKeyColumns'] |
1926 | 1926 | : $assoc['sourceToTargetKeyColumns']; |
1927 | 1927 | |
1928 | - foreach ($columns as $column){ |
|
1928 | + foreach ($columns as $column) { |
|
1929 | 1929 | $types[] = PersisterHelper::getTypeOfColumn($column, $class, $this->em); |
1930 | 1930 | } |
1931 | 1931 | break; |
@@ -1936,7 +1936,7 @@ discard block |
||
1936 | 1936 | } |
1937 | 1937 | |
1938 | 1938 | if (is_array($value)) { |
1939 | - return array_map(function ($type) { |
|
1939 | + return array_map(function($type) { |
|
1940 | 1940 | $type = Type::getType($type); |
1941 | 1941 | |
1942 | 1942 | return $type->getBindingType() + Connection::ARRAY_PARAM_OFFSET; |
@@ -2012,12 +2012,12 @@ discard block |
||
2012 | 2012 | |
2013 | 2013 | $sql = 'SELECT 1 ' |
2014 | 2014 | . $this->getLockTablesSql(null) |
2015 | - . ' WHERE ' . $this->getSelectConditionSQL($criteria); |
|
2015 | + . ' WHERE '.$this->getSelectConditionSQL($criteria); |
|
2016 | 2016 | |
2017 | 2017 | list($params, $types) = $this->expandParameters($criteria); |
2018 | 2018 | |
2019 | 2019 | if (null !== $extraConditions) { |
2020 | - $sql .= ' AND ' . $this->getSelectConditionCriteriaSQL($extraConditions); |
|
2020 | + $sql .= ' AND '.$this->getSelectConditionCriteriaSQL($extraConditions); |
|
2021 | 2021 | list($criteriaParams, $criteriaTypes) = $this->expandCriteriaParameters($extraConditions); |
2022 | 2022 | |
2023 | 2023 | $params = array_merge($params, $criteriaParams); |
@@ -2025,7 +2025,7 @@ discard block |
||
2025 | 2025 | } |
2026 | 2026 | |
2027 | 2027 | if ($filterSql = $this->generateFilterConditionSQL($this->class, $alias)) { |
2028 | - $sql .= ' AND ' . $filterSql; |
|
2028 | + $sql .= ' AND '.$filterSql; |
|
2029 | 2029 | } |
2030 | 2030 | |
2031 | 2031 | return (bool) $this->conn->fetchColumn($sql, $params, 0, $types); |
@@ -2072,13 +2072,13 @@ discard block |
||
2072 | 2072 | |
2073 | 2073 | foreach ($this->em->getFilters()->getEnabledFilters() as $filter) { |
2074 | 2074 | if ('' !== $filterExpr = $filter->addFilterConstraint($targetEntity, $targetTableAlias)) { |
2075 | - $filterClauses[] = '(' . $filterExpr . ')'; |
|
2075 | + $filterClauses[] = '('.$filterExpr.')'; |
|
2076 | 2076 | } |
2077 | 2077 | } |
2078 | 2078 | |
2079 | 2079 | $sql = implode(' AND ', $filterClauses); |
2080 | 2080 | |
2081 | - return $sql ? "(" . $sql . ")" : ""; // Wrap again to avoid "X or Y and FilterConditionSQL" |
|
2081 | + return $sql ? "(".$sql.")" : ""; // Wrap again to avoid "X or Y and FilterConditionSQL" |
|
2082 | 2082 | } |
2083 | 2083 | |
2084 | 2084 | /** |
@@ -2108,7 +2108,7 @@ discard block |
||
2108 | 2108 | $entityManager = $this->em; |
2109 | 2109 | |
2110 | 2110 | return array_map( |
2111 | - static function ($fieldName) use ($class, $entityManager) : string { |
|
2111 | + static function($fieldName) use ($class, $entityManager) : string { |
|
2112 | 2112 | $types = PersisterHelper::getTypeOfField($fieldName, $class, $entityManager); |
2113 | 2113 | assert(isset($types[0])); |
2114 | 2114 |