Skip to content

Commit

Permalink
Add middleware tests
Browse files Browse the repository at this point in the history
  • Loading branch information
francbartoli committed Nov 1, 2024
1 parent 80184db commit 96f42cd
Show file tree
Hide file tree
Showing 5 changed files with 310 additions and 244 deletions.
2 changes: 0 additions & 2 deletions app/main.py
Original file line number Diff line number Diff line change
Expand Up @@ -20,7 +20,6 @@
from pygeoapi.provider.base import ProviderConnectionError
from starlette.exceptions import HTTPException as StarletteHTTPException
from starlette.middleware.cors import CORSMiddleware
from uvicorn.middleware.proxy_headers import ProxyHeadersMiddleware

from app.config.app import configuration as cfg
from app.config.logging import create_logger
Expand Down Expand Up @@ -128,7 +127,6 @@ async def custom_app_exception_handler(request, e):
],
)
if cfg.FASTGEOAPI_REVERSE_PROXY:
patched_app.add_middleware(ProxyHeadersMiddleware)
patched_app.add_middleware(ForwardedLinksMiddleware)

except FileNotFoundError:
Expand Down
Loading

0 comments on commit 96f42cd

Please sign in to comment.