Skip to content

Commit 527c49c

Browse files
committed
Fix scrutinizer
1 parent 1dcfba2 commit 527c49c

File tree

2 files changed

+4
-2
lines changed

2 files changed

+4
-2
lines changed

src/Factory/Type/FilterTypeFactory.php

Lines changed: 3 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -171,8 +171,9 @@ private function getConditionFieldsType(string $className, string $typeName): In
171171

172172
// Get all entity scalar fields
173173
foreach ($metadata->fieldMappings as $mapping) {
174-
$fieldName = $mapping['fieldName'];
174+
/** @var LeafType $leafType */
175175
$leafType = $this->types->get($mapping['type']);
176+
$fieldName = $mapping['fieldName'];
176177

177178
$field = [
178179
'name' => $fieldName,
@@ -223,6 +224,7 @@ private function getCustomFiltersFromAnnotation(ReflectionClass $class): array
223224
$className = $filter->operator;
224225
$this->throwIfInvalidAnnotation($class, 'Filter', AbstractOperator::class, $className);
225226

227+
/** @var LeafType $leafType */
226228
$leafType = $this->types->get($filter->type);
227229
$instance = $this->types->getOperator($className, $leafType);
228230

src/Factory/Type/SortingTypeFactory.php

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -120,7 +120,7 @@ private function fillCache(string $className): void
120120
}
121121

122122
$class = new ReflectionClass($className);
123-
$this->customSortings[$className] = $customSort = $this->getFromAnnotation($class);
123+
$this->customSortings[$className] = $this->getFromAnnotation($class);
124124
}
125125

126126
/**

0 commit comments

Comments
 (0)