We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
There was an error while loading. Please reload this page.
1 parent 6d84e16 commit deade75Copy full SHA for deade75
extractor/extract.php
@@ -491,7 +491,11 @@ private function compareFunctions(Node\FunctionLike $old, Node\FunctionLike $new
491
492
return !$child->value instanceof ReturnTagValueNode;
493
})));
494
- $new->setDocComment(new Comment\Doc((string) $newPhpDocNodeWithoutReturn));
+ if (count($newPhpDocNodeWithoutReturn->children) === 0) {
495
+ $new->setAttribute('comments', []);
496
+ } else {
497
+ $new->setDocComment(new Comment\Doc((string) $newPhpDocNodeWithoutReturn));
498
+ }
499
}
500
501
0 commit comments