Browse Source

Merge pull request #96 from robtesch/master

Fix openapi route
Shalvah 4 năm trước cách đây
mục cha
commit
091c71f663
1 tập tin đã thay đổi với 6 bổ sung3 xóa
  1. 6 3
      src/Http/Controller.php

+ 6 - 3
src/Http/Controller.php

@@ -23,10 +23,13 @@ class Controller
         );
     }
 
+    /**
+     * @throws \Illuminate\Contracts\Filesystem\FileNotFoundException
+     *
+     * @return \Symfony\Component\HttpFoundation\BinaryFileResponse
+     */
     public function openapi()
     {
-        return response()->json(
-            json_decode(Storage::disk('local')->get('scribe/openapi.yaml'))
-        );
+        return response()->file(Storage::path('scribe/openapi.yaml'));
     }
 }