UPDATE
This commit is contained in:
+6
-7
@@ -18,10 +18,7 @@ INSTALLED_APPS = [
|
||||
"django.contrib.sessions",
|
||||
"django.contrib.messages",
|
||||
"django.contrib.staticfiles",
|
||||
"auth.apps.AuthConfig",
|
||||
"account",
|
||||
"sensor_hub",
|
||||
"dashboard",
|
||||
"ingest",
|
||||
"rest_framework",
|
||||
"corsheaders",
|
||||
]
|
||||
@@ -98,9 +95,11 @@ REST_FRAMEWORK = {
|
||||
"DEFAULT_PERMISSION_CLASSES": [
|
||||
"rest_framework.permissions.AllowAny",
|
||||
],
|
||||
"DEFAULT_AUTHENTICATION_CLASSES": [
|
||||
"rest_framework_simplejwt.authentication.JWTAuthentication",
|
||||
],
|
||||
}
|
||||
|
||||
if "rest_framework_simplejwt" in INSTALLED_APPS:
|
||||
REST_FRAMEWORK["DEFAULT_AUTHENTICATION_CLASSES"] = [
|
||||
"rest_framework_simplejwt.authentication.JWTAuthentication",
|
||||
]
|
||||
|
||||
CORS_ALLOW_ALL_ORIGINS = DEBUG
|
||||
|
||||
Reference in New Issue
Block a user