Spaces:
Sleeping
Sleeping
Update src/main.py
Browse files- src/main.py +2 -2
src/main.py
CHANGED
|
@@ -12,11 +12,11 @@ def create_app():
|
|
| 12 |
)
|
| 13 |
# Get allowed origins from environment variable or use defaults
|
| 14 |
# Support multiple origins separated by commas
|
| 15 |
-
allowed_origins_str = os.getenv("ALLOWED_ORIGINS", "https://full-stack-the-evolution-of-todo.vercel.app")
|
| 16 |
allowed_origins = [origin.strip() for origin in allowed_origins_str.split(",")]
|
| 17 |
|
| 18 |
# Also add common Vercel patterns if not already included
|
| 19 |
-
vercel_url =
|
| 20 |
if vercel_url and vercel_url not in allowed_origins:
|
| 21 |
# Add both http and https versions
|
| 22 |
if not vercel_url.startswith("http"):
|
|
|
|
| 12 |
)
|
| 13 |
# Get allowed origins from environment variable or use defaults
|
| 14 |
# Support multiple origins separated by commas
|
| 15 |
+
allowed_origins_str = os.getenv("ALLOWED_ORIGINS", "https://full-stack-the-evolution-of-todo.vercel.app", "http://localhost:3000")
|
| 16 |
allowed_origins = [origin.strip() for origin in allowed_origins_str.split(",")]
|
| 17 |
|
| 18 |
# Also add common Vercel patterns if not already included
|
| 19 |
+
vercel_url = "https://full-stack-the-evolution-of-todo.vercel.app"
|
| 20 |
if vercel_url and vercel_url not in allowed_origins:
|
| 21 |
# Add both http and https versions
|
| 22 |
if not vercel_url.startswith("http"):
|