diff --git a/src/Builders/Paths/Operation/ParametersBuilder.php b/src/Builders/Paths/Operation/ParametersBuilder.php index 2333690..9d376fc 100644 --- a/src/Builders/Paths/Operation/ParametersBuilder.php +++ b/src/Builders/Paths/Operation/ParametersBuilder.php @@ -39,7 +39,9 @@ protected function buildPath(RouteInformation $route): Collection return null; } - $schema = SchemaHelpers::guessFromReflectionType($reflectionParameter->getType()); + if ($reflectionParameter->getType() instanceof \ReflectionNamedType) { + $schema = SchemaHelpers::guessFromReflectionType($reflectionParameter->getType()); + } } /** @var Param $description */