Ashrafb commited on
Commit
60a24c5
1 Parent(s): 9591917

Update main.py

Browse files
Files changed (1) hide show
  1. main.py +3 -3
main.py CHANGED
@@ -48,10 +48,10 @@ from fastapi.middleware.cors import CORSMiddleware
48
 
49
  app.add_middleware(
50
  CORSMiddleware,
51
- allow_origins=["https://artixiban-ll3.static.hf.space"], # Adjust as needed, '*' allows requests from any origin
52
  allow_credentials=True,
53
- allow_methods=["*"],
54
- allow_headers=["*"],
55
  )
56
 
57
  @app.post("/generate/")
 
48
 
49
  app.add_middleware(
50
  CORSMiddleware,
51
+ allow_origins=["https://artixiban-ll3.static.hf.space"], # Allow only this origin
52
  allow_credentials=True,
53
+ allow_methods=["*"], # Allow all methods (GET, POST, etc.)
54
+ allow_headers=["*"], # Allow all headers
55
  )
56
 
57
  @app.post("/generate/")