@@ -54,7 +54,7 @@ |
||
54 | 54 | }; |
55 | 55 | $this->functionDescriptionParsers[ODataConstants::STRFUN_ENDSWITH] = function ($params) { |
56 | 56 | return '(strcmp(substr(' . $params[0] . ', strlen(' . $params[0] . ') - strlen(' . $params[1] . ')), ' |
57 | - .$params[1] . ') === 0)'; |
|
57 | + .$params[1] . ') === 0)'; |
|
58 | 58 | }; |
59 | 59 | $this->functionDescriptionParsers[ODataConstants::STRFUN_INDEXOF] = function ($params) { |
60 | 60 | return 'strpos(' . $params[0] . ', ' . $params[1] . ')'; |
@@ -70,7 +70,7 @@ |
||
70 | 70 | $others = $this->getRelationsByRelationName($className, $relName); |
71 | 71 | if ($stub instanceof AssociationStubMonomorphic) { |
72 | 72 | $msg = 'Monomorphic relation stub on ' . $className . ' ' . $relName |
73 | - . ' should point to at most 1 other stub'; |
|
73 | + . ' should point to at most 1 other stub'; |
|
74 | 74 | if (!(1 >= count($others))) { |
75 | 75 | throw new InvalidOperationException($msg); |
76 | 76 | } |
@@ -186,8 +186,8 @@ |
||
186 | 186 | */ |
187 | 187 | protected function updateLightStack(int $newCount) |
188 | 188 | { |
189 | - $this->lightStack[$newCount - 1]['count']--; |
|
190 | - if (0 == $this->lightStack[$newCount - 1]['count']) { |
|
189 | + $this->lightStack[$newCount-1]['count']--; |
|
190 | + if (0 == $this->lightStack[$newCount-1]['count']) { |
|
191 | 191 | array_pop($this->lightStack); |
192 | 192 | } |
193 | 193 | } |
@@ -63,7 +63,7 @@ |
||
63 | 63 | { |
64 | 64 | $class = __CLASS__; |
65 | 65 | if (!isset($classMap[$class])) { |
66 | - throw new \Exception(sprintf('%s was not found in autoload class map, this usually indicates you '. |
|
66 | + throw new \Exception(sprintf('%s was not found in autoload class map, this usually indicates you ' . |
|
67 | 67 | 'need to dump an optimised autoloader (`composer dump-autoload -o`)', $class)); |
68 | 68 | } |
69 | 69 | } |
@@ -261,10 +261,10 @@ |
||
261 | 261 | |
262 | 262 | private static $fieldOrderCache = [ |
263 | 263 | 'BelongsTo' => ['foreignKey', 'ownerKey'], |
264 | - 'BelongsToMany' => ['parentKey','foreignPivotKey','relatedPivotKey','relatedKey'], |
|
265 | - 'HasOneOrMany' => ['localKey', 'foreignKey' ], |
|
264 | + 'BelongsToMany' => ['parentKey', 'foreignPivotKey', 'relatedPivotKey', 'relatedKey'], |
|
265 | + 'HasOneOrMany' => ['localKey', 'foreignKey'], |
|
266 | 266 | 'HasManyThrough' => ['localKey', 'firstKey', 'secondLocalKey', 'secondKey'], |
267 | - 'MorphToMany' => ['parentKey','foreignPivotKey','morphType', 'relatedPivotKey','relatedKey'], |
|
267 | + 'MorphToMany' => ['parentKey', 'foreignPivotKey', 'morphType', 'relatedPivotKey', 'relatedKey'], |
|
268 | 268 | 'MorphTo' => ['foreignKey', 'morphType', 'ownerKey'], |
269 | 269 | 'MorphOneOrMany' => ['foreignKey', 'morphType', 'localKey'], |
270 | 270 | 'inverse' => ['inverse'], // TODO: currently used to get inverse, should be removed when morphtomany is fixed |
@@ -369,7 +369,7 @@ |
||
369 | 369 | $builder = $connect->getSchemaBuilder(); |
370 | 370 | $columns = $builder->getColumnListing($table); |
371 | 371 | |
372 | - self::$tableColumns = (array)$columns; |
|
372 | + self::$tableColumns = (array) $columns; |
|
373 | 373 | } |
374 | 374 | return self::$tableColumns; |
375 | 375 | } |
@@ -37,7 +37,7 @@ |
||
37 | 37 | $values = $skipToken->getOrderByKeysInToken(); |
38 | 38 | $numValues = count($values); |
39 | 39 | if ($numValues != count($segments)) { |
40 | - $msg = 'Expected '.count($segments).', got '.$numValues; |
|
40 | + $msg = 'Expected ' . count($segments) . ', got ' . $numValues; |
|
41 | 41 | throw new InvalidOperationException($msg); |
42 | 42 | } |
43 | 43 |
@@ -382,7 +382,7 @@ discard block |
||
382 | 382 | // so we can't bail out early |
383 | 383 | $rawCount += $results->count(); |
384 | 384 | // now bolt on filtrate to accumulating result set if we haven't accumulated enough bitz |
385 | - if ($rawTop > $resultSet->count() + $skip) { |
|
385 | + if ($rawTop > $resultSet->count()+$skip) { |
|
386 | 386 | $resultSet = collect(array_merge($resultSet->all(), $results->all())); |
387 | 387 | $sliceAmount = min($skip, $resultSet->count()); |
388 | 388 | $resultSet = $resultSet->slice($sliceAmount); |
@@ -454,7 +454,7 @@ discard block |
||
454 | 454 | if (QueryType::COUNT() == $qVal || QueryType::ENTITIES_WITH_COUNT() == $qVal) { |
455 | 455 | $result->count = $resultCount; |
456 | 456 | } |
457 | - $hazMore = $bulkSetCount > $skip + count($resultSet); |
|
457 | + $hazMore = $bulkSetCount > $skip+count($resultSet); |
|
458 | 458 | $result->hasMore = $hazMore; |
459 | 459 | } |
460 | 460 | } |
@@ -35,6 +35,6 @@ |
||
35 | 35 | public function getRelationships() |
36 | 36 | { |
37 | 37 | return self::$relationNames = self::$relationNames ?? |
38 | - ModelReflectionHelper::getRelationshipsFromMethods(/* @scrutinizer ignore-type */$this); |
|
38 | + ModelReflectionHelper::getRelationshipsFromMethods(/* @scrutinizer ignore-type */$this); |
|
39 | 39 | } |
40 | 40 | } |