File tree Expand file tree Collapse file tree 1 file changed +6
-5
lines changed Expand file tree Collapse file tree 1 file changed +6
-5
lines changed Original file line number Diff line number Diff line change @@ -51,14 +51,15 @@ public function generate()
51
51
$ this ->docs ['paths ' ][$ this ->uri ] = [];
52
52
}
53
53
54
- $ this ->addAuthParameters ($ route ->middleware ());
55
-
54
+
56
55
foreach ($ methods as $ method ) {
57
56
$ this ->method = strtolower ($ method );
58
-
57
+
59
58
if (in_array ($ this ->method , $ this ->config ['ignoredMethods ' ])) continue ;
60
-
59
+
61
60
$ this ->generatePath ();
61
+
62
+ $ this ->addAuthParameters ($ route ->middleware ());
62
63
}
63
64
}
64
65
@@ -188,7 +189,7 @@ protected function addAuthParameters($middlewares)
188
189
return (strpos ($ var , 'jwt ' ) > -1 );
189
190
});
190
191
if ($ hasAuth ) {
191
- $ this ->docs ['paths ' ]['security ' ] = [
192
+ $ this ->docs ['paths ' ][$ this -> uri ][ $ this -> method ][ 'security ' ] = [
192
193
'api_key ' => []
193
194
];
194
195
}
You can’t perform that action at this time.
0 commit comments