File tree Expand file tree Collapse file tree 2 files changed +7
-6
lines changed Expand file tree Collapse file tree 2 files changed +7
-6
lines changed Original file line number Diff line number Diff line change 9292 | `RonasIT\Support\AutoDoc\Interfaces\SwaggerDriverInterface` interface,
9393 | or one of our drivers from the `drivers` config:
9494 */
95- 'driver ' => ' local ' ,
95+ 'driver ' => env ( ' SWAGGER_DRIVER ' , ' local ') ,
9696
9797 'drivers ' => [
9898 'local ' => [
101101 ],
102102 'remote ' => [
103103 'class ' => RemoteDriver::class,
104- 'key ' => ' project_name ' ,
105- 'url ' => ' https://example.com '
104+ 'key ' => env ( ' SWAGGER_REMOTE_DRIVER_KEY ' , ' project_name ') ,
105+ 'url ' => env ( ' SWAGGER_REMOTE_DRIVER_URL ' , ' https://example.com ')
106106 ],
107107 'storage ' => [
108108 'class ' => StorageDriver::class,
114114 |
115115 | One of the filesystems.disks config value
116116 */
117- 'disk ' => ' public ' ,
117+ 'disk ' => env ( ' SWAGGER_STORAGE_DRIVER_DISK ' , ' public ') ,
118118 'production_path ' => 'documentation.json '
119119 ]
120120 ],
131131 'development '
132132 ],
133133
134- 'config_version ' => '2.0 '
134+ 'config_version ' => '2.1 '
135135];
Original file line number Diff line number Diff line change @@ -40,8 +40,9 @@ public function saveData()
4040
4141 curl_setopt ($ curl , CURLOPT_URL , $ this ->getUrl ());
4242 curl_setopt ($ curl , CURLOPT_POST , true );
43- curl_setopt ($ curl , CURLOPT_POSTFIELDS , http_build_query ($ this ->getTmpData ()));
43+ curl_setopt ($ curl , CURLOPT_POSTFIELDS , json_encode ($ this ->getTmpData ()));
4444 curl_setopt ($ curl , CURLOPT_RETURNTRANSFER , true );
45+ curl_setopt ($ curl , CURLOPT_HTTPHEADER , ['Content-Type: application/json ' ]);
4546
4647 curl_exec ($ curl );
4748 curl_close ($ curl );
You can’t perform that action at this time.
0 commit comments