diff --git a/app.py b/app.py index 3d43bf4..b4b714f 100644 --- a/app.py +++ b/app.py @@ -6,15 +6,15 @@ import json import os from starlette.middleware.httpsredirect import HTTPSRedirectMiddleware + from fastapi.middleware.trustedhost import TrustedHostMiddleware -from starlette.middleware.proxy_headers import ProxyHeadersMiddleware + app = FastAPI() # Mount static files app.mount("/static", StaticFiles(directory="static"), name="static") app.add_middleware( HTTPSRedirectMiddleware ) -app.add_middleware(ProxyHeadersMiddleware) app.add_middleware(TrustedHostMiddleware, allowed_hosts=["*"])