Skip to content

Commit

Permalink
Fixed psalm errors
Browse files Browse the repository at this point in the history
  • Loading branch information
ricardoboss committed Dec 5, 2021
1 parent 93dfc60 commit 5872f66
Showing 1 changed file with 3 additions and 2 deletions.
Expand Up @@ -35,13 +35,14 @@ public static function getFunctionReturnType(FunctionReturnTypeProviderEvent $ev
$num_arg = $nodeTypeProvider->getType($call_args[0]->value);

if (count($call_args) > 1) {
$precision_val = $call_args[1]->value;
$precision_val = (int)$call_args[1]->value;
} else {
$precision_val = 0;
}

if (count($call_args) > 2) {
$mode_val = $call_args[2]->value;
/** @var positive-int|0 $mode_val */
$mode_val = (int)$call_args[2]->value;
} else {
$mode_val = PHP_ROUND_HALF_UP;
}
Expand Down

0 comments on commit 5872f66

Please sign in to comment.