@@ -135,7 +135,7 @@ |
||
| 135 | 135 | $stub = clone $this->knownSides[$knownType][$key]; |
| 136 | 136 | $isMulti = ($stub->getMultiplicity()->getValue() == AssociationStubRelationType::MANY); |
| 137 | 137 | $relPolyTypeName = substr($lc->getBaseType(), strrpos($lc->getBaseType(), '\\')+1); |
| 138 | - $relPolyTypeName = str_plural($relPolyTypeName, $isMulti?2:1); |
|
| 138 | + $relPolyTypeName = str_plural($relPolyTypeName, $isMulti ? 2 : 1); |
|
| 139 | 139 | $stub->setRelationName($stub->getRelationName() . '_' . $relPolyTypeName); |
| 140 | 140 | $assoc = new AssociationMonomorphic(); |
| 141 | 141 | $first = -1 === $stub->compare($lc); |
@@ -142,7 +142,7 @@ |
||
| 142 | 142 | $metaCount = count($meta->oDataEntityMap); |
| 143 | 143 | $entityCount = count($entities); |
| 144 | 144 | $expected = 2 * $entityCount; |
| 145 | - assert($metaCount == $expected, 'Expected ' . $expected . ' items, actually got '.$metaCount); |
|
| 145 | + assert($metaCount == $expected, 'Expected ' . $expected . ' items, actually got ' . $metaCount); |
|
| 146 | 146 | |
| 147 | 147 | if (0 === count($objectModel->getAssociations())) { |
| 148 | 148 | return; |
@@ -119,13 +119,13 @@ discard block |
||
| 119 | 119 | public function setFields(array $fields) |
| 120 | 120 | { |
| 121 | 121 | if (0 == count($fields)) { |
| 122 | - $msg = 'Fields array must not be empty for '.$this->getClassName(); |
|
| 122 | + $msg = 'Fields array must not be empty for ' . $this->getClassName(); |
|
| 123 | 123 | throw new \Exception($msg); |
| 124 | 124 | } |
| 125 | 125 | $keys = []; |
| 126 | 126 | foreach ($fields as $propName => $field) { |
| 127 | 127 | if (!$field instanceof EntityField) { |
| 128 | - $msg = 'Fields array must only have EntityField objects for '.$this->getClassName(); |
|
| 128 | + $msg = 'Fields array must only have EntityField objects for ' . $this->getClassName(); |
|
| 129 | 129 | throw new \Exception($msg); |
| 130 | 130 | } |
| 131 | 131 | if ($field->getIsKeyField()) { |
@@ -133,7 +133,7 @@ discard block |
||
| 133 | 133 | } |
| 134 | 134 | } |
| 135 | 135 | if (0 == count($keys)) { |
| 136 | - $msg = 'No key field supplied in fields array for '.$this->getClassName(); |
|
| 136 | + $msg = 'No key field supplied in fields array for ' . $this->getClassName(); |
|
| 137 | 137 | throw new \Exception($msg); |
| 138 | 138 | } |
| 139 | 139 | $this->fields = $fields; |
@@ -103,7 +103,7 @@ discard block |
||
| 103 | 103 | foreach ($order->getSubPathSegments() as $subOrder) { |
| 104 | 104 | $subName = $subOrder->getName(); |
| 105 | 105 | $subName = (self::PK == $subName) ? $keyName : $subName; |
| 106 | - $subName = $tableName.'.'.$subName; |
|
| 106 | + $subName = $tableName . '.' . $subName; |
|
| 107 | 107 | $sourceEntityInstance = $sourceEntityInstance->orderBy( |
| 108 | 108 | $subName, |
| 109 | 109 | $order->isAscending() ? 'asc' : 'desc' |
@@ -425,7 +425,7 @@ discard block |
||
| 425 | 425 | assert(is_string($line), 'Eager-load elements must be non-empty strings'); |
| 426 | 426 | $lineParts = explode('/', $line); |
| 427 | 427 | $numberOfParts = count($lineParts); |
| 428 | - for ($i = 0; $i<$numberOfParts; $i++) { |
|
| 428 | + for ($i = 0; $i < $numberOfParts; $i++) { |
|
| 429 | 429 | $lineParts[$i] = $this->getLaravelRelationName($lineParts[$i]); |
| 430 | 430 | } |
| 431 | 431 | $remixLine = implode('.', $lineParts); |
@@ -507,7 +507,7 @@ discard block |
||
| 507 | 507 | // so we can't bail out early |
| 508 | 508 | $rawCount += $results->count(); |
| 509 | 509 | // now bolt on filtrate to accumulating result set if we haven't accumulated enough bitz |
| 510 | - if ($rawTop > $resultSet->count() + $skip) { |
|
| 510 | + if ($rawTop > $resultSet->count()+$skip) { |
|
| 511 | 511 | $resultSet = collect(array_merge($resultSet->all(), $results->all())); |
| 512 | 512 | $sliceAmount = min($skip, $resultSet->count()); |
| 513 | 513 | $resultSet = $resultSet->slice($sliceAmount); |