Skip to content

Commit

Permalink
fix phpstan errors
Browse files Browse the repository at this point in the history
  • Loading branch information
priyadi committed Mar 30, 2024
1 parent 5e155c3 commit 00e21a8
Show file tree
Hide file tree
Showing 2 changed files with 9 additions and 5 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -122,7 +122,7 @@ private function getQueryBuilder(
$queryBuilder->setParameter(
"rekapager_where_{$z}",
$excludeProperty['value'],
// @phpstan-ignore-next-line ORM 2 compatibility
// @phpstan-ignore-next-line
$this->getType($excludeProperty['property'])
);

Expand All @@ -138,7 +138,7 @@ private function getQueryBuilder(
$queryBuilder->setParameter(
"rekapager_where_{$z}",
$property['value'],
// @phpstan-ignore-next-line ORM 2 compatibility
// @phpstan-ignore-next-line
$this->getType($property['property'])
);

Expand All @@ -152,7 +152,7 @@ private function getQueryBuilder(
$queryBuilder->setParameter(
"rekapager_where_{$z}",
$property['value'],
// @phpstan-ignore-next-line ORM 2 compatibility
// @phpstan-ignore-next-line
$this->getType($property['property'])
);

Expand Down Expand Up @@ -312,7 +312,10 @@ private function getReversedSortOrder(): array
return $result;
}

private function getType(string $name): ParameterType|ArrayParameterType|string|int|null
/**
* @return ParameterType|ArrayParameterType|string|int|null
*/
private function getType(string $name): mixed
{
return $this->typeMapping[$name] ?? null;
}
Expand Down
3 changes: 2 additions & 1 deletion phpstan.neon.dist
Original file line number Diff line number Diff line change
Expand Up @@ -5,7 +5,8 @@ parameters:
checkFunctionNameCase: true
checkInternalClassCaseSensitivity: true
reportMaybesInPropertyPhpDocTypes: true
treatPhpDocTypesAsCertain: false
treatPhpDocTypesAsCertain: false
reportUnmatchedIgnoredErrors: false
paths:
- packages
- tests
Expand Down

0 comments on commit 00e21a8

Please sign in to comment.