Skip to content

Commit

Permalink
reducing filesize a bit with smaller property comment blocks (#132)
Browse files Browse the repository at this point in the history
  • Loading branch information
dcarbone authored Aug 7, 2024
1 parent 5b0460b commit 19a4222
Showing 1 changed file with 5 additions and 4 deletions.
9 changes: 5 additions & 4 deletions template/types/properties/declaration.php
Original file line number Diff line number Diff line change
Expand Up @@ -26,13 +26,14 @@
$documentation = DocumentationUtils::compilePropertyDocumentation($property, 5, true);

ob_start(); ?>
/**<?php if ('' !== $documentation) : ?>

<?php if ('' === $documentation) : ?>
/** @var <?php echo TypeHintUtils::propertyGetterTypeDoc($config, $property, true); ?> */
<?php else : ?>
/**
<?php echo $documentation; ?>
*<?php endif; ?>

* @var <?php echo TypeHintUtils::propertyGetterTypeDoc($config, $property, true); ?>

*/
<?php endif; ?>
protected <?php echo TypeHintUtils::propertyTypeHint($config, $property, true); ?> $<?php echo $property->getName(); ?> = <?php echo $isCollection ? '[]' : 'null'; ?>;
<?php return ob_get_clean();

0 comments on commit 19a4222

Please sign in to comment.