From 59c2d7f1659956a83ab35fe0550209427b53b29c Mon Sep 17 00:00:00 2001 From: K0IN <19688162+K0IN@users.noreply.github.com> Date: Tue, 3 Aug 2021 08:02:52 +0200 Subject: [PATCH] Resolve bug where static files not displaying for openapi2 (#243) --- sanic_openapi/openapi2/blueprint.py | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/sanic_openapi/openapi2/blueprint.py b/sanic_openapi/openapi2/blueprint.py index 444cb02..a914068 100644 --- a/sanic_openapi/openapi2/blueprint.py +++ b/sanic_openapi/openapi2/blueprint.py @@ -24,7 +24,7 @@ def blueprint_factory(): swagger_blueprint.static( "/", dir_path + "/index.html", strict_slashes=True ) - swagger_blueprint.static("/", dir_path) + swagger_blueprint.static("", dir_path) # Redirect "/swagger" to "/swagger/" @swagger_blueprint.route("", strict_slashes=True)