From 30a8a59906ee727c3e99322f7aeaf280a211bafa Mon Sep 17 00:00:00 2001 From: Spitap Date: Sat, 11 Feb 2023 16:41:44 +0100 Subject: [PATCH] Fixed default new-admin url --- modoboa/core/commands/templates/settings.py.tpl | 2 +- modoboa/core/context_processors.py | 2 +- test_project/test_project/settings.py | 2 +- 3 files changed, 3 insertions(+), 3 deletions(-) diff --git a/modoboa/core/commands/templates/settings.py.tpl b/modoboa/core/commands/templates/settings.py.tpl index 22bf058ee..3c46fb253 100644 --- a/modoboa/core/commands/templates/settings.py.tpl +++ b/modoboa/core/commands/templates/settings.py.tpl @@ -213,7 +213,7 @@ REST_FRAMEWORK = { } # Uncomment if you need a custom sub url for new_admin interface -# NEW_ADMIN_URL = 'new_admin' +# NEW_ADMIN_URL = 'new-admin' SPECTACULAR_SETTINGS = { 'SCHEMA_PATH_PREFIX': r'/api/v[0-9]', diff --git a/modoboa/core/context_processors.py b/modoboa/core/context_processors.py index 2f9126ec4..6b967b758 100644 --- a/modoboa/core/context_processors.py +++ b/modoboa/core/context_processors.py @@ -25,5 +25,5 @@ def top_notifications(request): def new_admin_url(*args): """A context processor to include new admin url.""" return { - "new_admin": getattr(settings, "NEW_ADMIN_URL", "new_admin") + "new_admin": getattr(settings, "NEW_ADMIN_URL", "new-admin") } diff --git a/test_project/test_project/settings.py b/test_project/test_project/settings.py index f0d1b63de..19ce64b57 100644 --- a/test_project/test_project/settings.py +++ b/test_project/test_project/settings.py @@ -205,7 +205,7 @@ REST_FRAMEWORK = { } # Uncomment if you need a custom sub url for new_admin interface -# NEW_ADMIN_URL = 'new_admin' +# NEW_ADMIN_URL = 'new-admin' SPECTACULAR_SETTINGS = { 'SCHEMA_PATH_PREFIX': r'/api/v[0-9]',