Skip to content

Commit 342dc60

Browse files
committed
[CodeQuality] Skip docblock based type on AddReturnTypeToDependedRector
1 parent d76a45a commit 342dc60

File tree

1 file changed

+1
-1
lines changed

1 file changed

+1
-1
lines changed

rules/CodeQuality/Rector/Class_/AddReturnTypeToDependedRector.php

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -112,7 +112,7 @@ public function refactor(Node $node): ?Node
112112
$soleReturnExpr = $returns[0]->expr;
113113

114114
// does return a type?
115-
$returnedExprType = $this->getType($soleReturnExpr);
115+
$returnedExprType = $this->nodeTypeResolver->getNativeType($soleReturnExpr);
116116
$returnType = $this->staticTypeMapper->mapPHPStanTypeToPhpParserNode($returnedExprType, TypeKind::RETURN);
117117

118118
if (! $returnType instanceof Node) {

0 commit comments

Comments
 (0)