@@ -24,29 +24,29 @@ public function boot(): void
24
24
{
25
25
if ($ this ->app ->runningInConsole ()) {
26
26
$ this ->publishes ([
27
- __DIR__ . '/../config/openapi.php ' => config_path ('openapi.php ' ),
27
+ __DIR__ . '/../config/openapi.php ' => config_path ('openapi.php ' ),
28
28
], 'openapi-config ' );
29
29
}
30
30
31
31
$ this ->registerAnnotations ();
32
32
33
- $ this ->app ->bind (CallbacksBuilder::class, function () {
33
+ $ this ->app ->bind (CallbacksBuilder::class, function () {
34
34
return new CallbacksBuilder ($ this ->getPathsFromConfig ('callbacks ' ));
35
35
});
36
36
37
- $ this ->app ->bind (RequestBodiesBuilder::class, function () {
37
+ $ this ->app ->bind (RequestBodiesBuilder::class, function () {
38
38
return new RequestBodiesBuilder ($ this ->getPathsFromConfig ('request_bodies ' ));
39
39
});
40
40
41
- $ this ->app ->bind (ResponsesBuilder::class, function () {
41
+ $ this ->app ->bind (ResponsesBuilder::class, function () {
42
42
return new ResponsesBuilder ($ this ->getPathsFromConfig ('responses ' ));
43
43
});
44
44
45
- $ this ->app ->bind (SchemasBuilder::class, function ($ app ) {
45
+ $ this ->app ->bind (SchemasBuilder::class, function ($ app ) {
46
46
return new SchemasBuilder ($ this ->getPathsFromConfig ('schemas ' ));
47
47
});
48
48
49
- $ this ->app ->bind (SecuritySchemesBuilder::class, function () {
49
+ $ this ->app ->bind (SecuritySchemesBuilder::class, function () {
50
50
return new SecuritySchemesBuilder ($ this ->getPathsFromConfig ('security_schemes ' ));
51
51
});
52
52
@@ -63,13 +63,13 @@ public function boot(): void
63
63
);
64
64
});
65
65
66
- $ this ->loadRoutesFrom (__DIR__ . '/../routes/api.php ' );
66
+ $ this ->loadRoutesFrom (__DIR__ . '/../routes/api.php ' );
67
67
}
68
68
69
69
public function register (): void
70
70
{
71
71
$ this ->mergeConfigFrom (
72
- __DIR__ . '/../config/openapi.php ' ,
72
+ __DIR__ . '/../config/openapi.php ' ,
73
73
'openapi '
74
74
);
75
75
@@ -92,7 +92,7 @@ public function register(): void
92
92
93
93
protected function registerAnnotations (): void
94
94
{
95
- $ files = glob (__DIR__ . '/Annotations/*.php ' );
95
+ $ files = glob (__DIR__ . '/Annotations/*.php ' );
96
96
97
97
foreach ($ files as $ file ) {
98
98
AnnotationRegistry::registerFile ($ file );
@@ -101,7 +101,7 @@ protected function registerAnnotations(): void
101
101
102
102
private function getPathsFromConfig (string $ type ): array
103
103
{
104
- $ directories = config ('openapi.locations. ' . $ type , []);
104
+ $ directories = config ('openapi.locations. ' . $ type , []);
105
105
106
106
foreach ($ directories as &$ directory ) {
107
107
$ directory = glob ($ directory , GLOB_ONLYDIR );
0 commit comments