LT360 commited on
Commit
beecd3e
·
1 Parent(s): 0d4818b

Update CORS

Browse files
Files changed (1) hide show
  1. app/main.py +7 -1
app/main.py CHANGED
@@ -9,7 +9,13 @@ from .ml import get_model_prediction, check_model_status
9
  app = FastAPI(title="AI-Powered Phishing Email Detection System")
10
 
11
  # Define allowed origins for CORS
12
- origins = ["*"]
 
 
 
 
 
 
13
 
14
  app.add_middleware(
15
  CORSMiddleware,
 
9
  app = FastAPI(title="AI-Powered Phishing Email Detection System")
10
 
11
  # Define allowed origins for CORS
12
+ origins = [
13
+ "https://ai-powered-phishing-email-detection-system.vercel.app",
14
+ "http://localhost:3000",
15
+ "https://huggingface.co/spaces/lleratodev/multinomial-nb-phishing-email-detection-api",
16
+ "https://*.hf.space",
17
+ "https://huggingface.co/spaces/lleratodev/multinomial-nb-phishing-email-detection-api.hf.space"
18
+ ]
19
 
20
  app.add_middleware(
21
  CORSMiddleware,