mirror of
https://github.com/Part-DB/Part-DB-server.git
synced 2026-04-16 19:39:36 +00:00
Fixed phpstan issues
This commit is contained in:
parent
1c3dfa26bb
commit
ec05f9d8ab
2 changed files with 7 additions and 1 deletions
|
|
@ -59,6 +59,9 @@ parameters:
|
|||
- '#expects .*PartParameter, .*AbstractParameter given.#'
|
||||
- '#Part::getParameters\(\) should return .*AbstractParameter#'
|
||||
|
||||
# Fix some weird issue with how covariance with collections is solved
|
||||
- '#Method App\\Entity\\Base\\AbstractStructuralDBElement::getParameters\(\) should return Doctrine\\Common\\Collections\\Collection<int, App\\Entity\\Parameters\\AbstractParameter> but returns#'
|
||||
|
||||
# Ignore doctrine type mapping mismatch
|
||||
- '#Property .* type mapping mismatch: property can contain .* but database expects .*#'
|
||||
|
||||
|
|
@ -70,3 +73,6 @@ parameters:
|
|||
|
||||
- message: '#Access to an undefined property Brick\\Schema\\Interfaces\\#'
|
||||
path: src/Services/InfoProviderSystem/Providers/GenericWebProvider.php
|
||||
|
||||
-
|
||||
identifier: nullCoalesce.property
|
||||
|
|
|
|||
|
|
@ -189,7 +189,7 @@ class SiValueSort extends FunctionNode
|
|||
return $number;
|
||||
}
|
||||
|
||||
$multiplier = self::SI_MULTIPLIERS[$prefix] ?? 1.0;
|
||||
$multiplier = self::SI_MULTIPLIERS[$prefix] ?? 1.0; //@phpstan-ignore-line - fallback to 1.0 if prefix is not recognized (should not happen due to regex)
|
||||
|
||||
return $number * $multiplier;
|
||||
}
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue