From 2131b1554836bd6f06c6c49563e5f9669e7ec7d5 Mon Sep 17 00:00:00 2001 From: Sirin Puenggun Date: Thu, 23 Nov 2023 19:51:34 +0700 Subject: [PATCH] Update CORS setting production_settings.py --- backend/core/production_settings.py | 6 ++---- 1 file changed, 2 insertions(+), 4 deletions(-) diff --git a/backend/core/production_settings.py b/backend/core/production_settings.py index dd9eeb3..1ea23fb 100644 --- a/backend/core/production_settings.py +++ b/backend/core/production_settings.py @@ -123,10 +123,8 @@ CORS_ALLOW_ALL_ORIGINS = False CORS_ALLOWED_ORIGINS = [ "https://turtask.vercel.app", ] - CSRF_TRUSTED_ORIGINS = ["https://turtask.vercel.app"] - -CORS_ORIGIN_WHITELIST = ["*"] +CORS_ORIGIN_WHITELIST = ["https://turtask.vercel.app"] MIDDLEWARE = [ 'corsheaders.middleware.CorsMiddleware', @@ -264,4 +262,4 @@ STORAGES = { "staticfiles": { "BACKEND": "django.contrib.staticfiles.storage.StaticFilesStorage", }, -} \ No newline at end of file +}