File tree Expand file tree Collapse file tree 1 file changed +7
-2
lines changed
src/Builders/Paths/Operation Expand file tree Collapse file tree 1 file changed +7
-2
lines changed Original file line number Diff line number Diff line change @@ -34,8 +34,12 @@ protected function buildPath(RouteInformation $route): Collection
34
34
->first (static function (ReflectionParameter $ reflectionParameter ) use ($ parameter ) {
35
35
return $ reflectionParameter ->name === $ parameter ['name ' ];
36
36
});
37
-
37
+
38
38
if ($ reflectionParameter ) {
39
+ // The reflected param has no type, so ignore (should be defined in a ParametersFactory instead)
40
+ if ($ reflectionParameter ->getType () == null ) {
41
+ return null ;
42
+ }
39
43
$ schema = SchemaHelpers::guessFromReflectionType ($ reflectionParameter ->getType ());
40
44
}
41
45
@@ -49,7 +53,8 @@ protected function buildPath(RouteInformation $route): Collection
49
53
->required ()
50
54
->description (optional (optional ($ description )->getDescription ())->render ())
51
55
->schema ($ schema );
52
- });
56
+ })
57
+ ->filter ();
53
58
}
54
59
55
60
protected function buildAnnotation (RouteInformation $ route ): Collection
You can’t perform that action at this time.
0 commit comments