@@ -47,12 +47,12 @@ discard block |
||
| 47 | 47 | $collection = [ |
| 48 | 48 | 'variables' => [], |
| 49 | 49 | 'info' => [ |
| 50 | - 'name' => config('apidoc.postman.name') ?: config('app.name').' API', |
|
| 50 | + 'name' => config('apidoc.postman.name') ?: config('app.name') . ' API', |
|
| 51 | 51 | '_postman_id' => Uuid::uuid4()->toString(), |
| 52 | 52 | 'description' => config('apidoc.postman.description') ?: '', |
| 53 | 53 | 'schema' => 'https://schema.getpostman.com/json/collection/v2.0.0/collection.json', |
| 54 | 54 | ], |
| 55 | - 'item' => $this->routeGroups->map(function (Collection $routes, $groupName) { |
|
| 55 | + 'item' => $this->routeGroups->map(function(Collection $routes, $groupName) { |
|
| 56 | 56 | return [ |
| 57 | 57 | 'name' => $groupName, |
| 58 | 58 | 'description' => $routes->first()['metadata']['groupDescription'], |
@@ -104,7 +104,7 @@ discard block |
||
| 104 | 104 | ->union([ |
| 105 | 105 | 'Accept' => 'application/json', |
| 106 | 106 | ]) |
| 107 | - ->map(function ($value, $header) { |
|
| 107 | + ->map(function($value, $header) { |
|
| 108 | 108 | return [ |
| 109 | 109 | 'key' => $header, |
| 110 | 110 | 'value' => $value, |
@@ -125,10 +125,10 @@ discard block |
||
| 125 | 125 | 'protocol' => $this->protocol, |
| 126 | 126 | 'host' => $this->baseUrl, |
| 127 | 127 | // Substitute laravel/symfony query params ({example}) to Postman style, prefixed with a colon |
| 128 | - 'path' => preg_replace_callback('/\/{(\w+)\??}(?=\/|$)/', function ($matches) { |
|
| 128 | + 'path' => preg_replace_callback('/\/{(\w+)\??}(?=\/|$)/', function($matches) { |
|
| 129 | 129 | return '/:' . $matches[1]; |
| 130 | 130 | }, $route['uri']), |
| 131 | - 'query' => $queryParams->union($route['queryParameters'])->map(function ($parameter, $key) { |
|
| 131 | + 'query' => $queryParams->union($route['queryParameters'])->map(function($parameter, $key) { |
|
| 132 | 132 | return [ |
| 133 | 133 | 'key' => $key, |
| 134 | 134 | 'value' => $parameter['value'], |
@@ -145,7 +145,7 @@ discard block |
||
| 145 | 145 | return $base; |
| 146 | 146 | } |
| 147 | 147 | |
| 148 | - $base['variable'] = $urlParams->map(function ($parameter, $key) { |
|
| 148 | + $base['variable'] = $urlParams->map(function($parameter, $key) { |
|
| 149 | 149 | return [ |
| 150 | 150 | 'id' => $key, |
| 151 | 151 | 'key' => $key, |