Correcting an issue where there are two empty lines, first with an extra space, when there is no text to display on the first line. (#29)

This commit is contained in:
Joey Richard
2025-07-17 08:07:30 +02:00
committed by GitHub
parent 5a3e22c213
commit d103774cbe
@@ -207,7 +207,7 @@ class Serializer
}
$text = str_replace("\n", "\n{$indent} * ", $text);
$comment = "{$firstIndent}/**\n{$indent} * {$text}\n{$indent} *\n";
$comment = !empty($text)? "{$firstIndent}/**\n{$indent} * {$text}\n{$indent} *\n" : "{$firstIndent}/**\n";
$tags = array_values($docblock->getTags());