fix: complete public embed CORS handling

This commit is contained in:
Abhishek Kumar 2026-06-03 15:56:33 +00:00
parent 230ed1846e
commit c686025add
3 changed files with 379 additions and 109 deletions

View file

@ -117,6 +117,15 @@ app.add_middleware(
allow_headers=["*"],
)
def _add_public_embed_cors_middleware() -> None:
from api.routes.public_embed import PublicEmbedCORSMiddleware
app.add_middleware(PublicEmbedCORSMiddleware, api_prefix=API_PREFIX)
_add_public_embed_cors_middleware()
api_router = APIRouter()
# include subrouters here