Skip to content

Commit

Permalink
Remove CORS handling
Browse files Browse the repository at this point in the history
  • Loading branch information
cmyui committed Aug 1, 2024
1 parent 7f43ef6 commit a300059
Showing 1 changed file with 0 additions and 11 deletions.
11 changes: 0 additions & 11 deletions app/init_api.py
Original file line number Diff line number Diff line change
Expand Up @@ -7,7 +7,6 @@
from fastapi import FastAPI
from fastapi import Request
from fastapi import Response
from fastapi.middleware.cors import CORSMiddleware
from starlette.middleware.base import RequestResponseEndpoint

from app import logger
Expand Down Expand Up @@ -54,16 +53,6 @@ async def http_middleware(
logging.exception("Exception in ASGI application")
return Response(status_code=500)

app.add_middleware(
CORSMiddleware,
allow_origins=["https://next.akatsuki.gg", "http://localhost:3000"],
allow_methods=["*"],
allow_headers=["*"],
allow_credentials=True,
# NOTE: this does not expose credentials/http cookies
expose_headers=["*"],
)

return app


Expand Down

0 comments on commit a300059

Please sign in to comment.