Skip to content

Commit

Permalink
Remove unneeded var in narrowTypeForJsonDecode
Browse files Browse the repository at this point in the history
  • Loading branch information
herndlm committed Apr 26, 2022
1 parent 51ad1df commit b8357ff
Showing 1 changed file with 1 addition and 3 deletions.
4 changes: 1 addition & 3 deletions src/Type/Php/JsonThrowOnErrorDynamicReturnTypeExtension.php
Expand Up @@ -78,9 +78,7 @@ private function narrowTypeForJsonDecode(FuncCall $funcCall, Scope $scope, Type
$args = $funcCall->getArgs();
$isArrayWithoutStdClass = $this->isForceArrayWithoutStdClass($funcCall, $scope);

$firstArgValue = $args[0]->value;
$firstValueType = $scope->getType($firstArgValue);

$firstValueType = $scope->getType($args[0]->value);
if ($firstValueType instanceof ConstantStringType) {
return $this->resolveConstantStringType($firstValueType, $isArrayWithoutStdClass);
}
Expand Down

0 comments on commit b8357ff

Please sign in to comment.