diff --git a/src/Schema/ViewHelperFinder.php b/src/Schema/ViewHelperFinder.php index 85ad2240..a1808f21 100644 --- a/src/Schema/ViewHelperFinder.php +++ b/src/Schema/ViewHelperFinder.php @@ -23,7 +23,7 @@ final class ViewHelperFinder private ViewHelperMetadataFactory $viewHelperMetadataFactory; /** - * @var string[] $lastErrors + * @var \Throwable[] $lastErrors */ private array $lastErrors = []; @@ -93,7 +93,7 @@ private function findViewHelperFilesInPath(string $namespace, string $path): arr } catch (\Throwable $t) { // Catch all Throwables to mitigate technical debt of a ViewHelper // and avoid aborting the whole generation - $this->lastErrors[] = $t->getMessage(); + $this->lastErrors[] = $t; } } return $viewHelpers;