Explorar el Código

Merge pull request #13253 from noexcs/dev

fix: The value of the 'Access-Control-Allow-Origin' header in the res…
Tim Jaeryang Baek hace 10 meses
padre
commit
6d59a5f809
Se han modificado 1 ficheros con 1 adiciones y 1 borrados
  1. 1 1
      backend/open_webui/config.py

+ 1 - 1
backend/open_webui/config.py

@@ -1255,7 +1255,7 @@ def validate_cors_origin(origin):
 # To test CORS_ALLOW_ORIGIN locally, you can set something like
 # CORS_ALLOW_ORIGIN=http://localhost:5173;http://localhost:8080
 # in your .env file depending on your frontend port, 5173 in this case.
-CORS_ALLOW_ORIGIN = os.environ.get("CORS_ALLOW_ORIGIN", "*").split(";")
+CORS_ALLOW_ORIGIN = os.environ.get("CORS_ALLOW_ORIGIN", "*;http://localhost:5173;http://localhost:8080").split(";")
 
 if "*" in CORS_ALLOW_ORIGIN:
     log.warning(