From 480eff52db6dc0f9e6c8c2a0109b6a48a38bc474 Mon Sep 17 00:00:00 2001 From: Nick Sweeting Date: Tue, 19 Dec 2023 09:58:15 -0800 Subject: [PATCH] Update urls.py --- archivebox/core/urls.py | 4 +++- 1 file changed, 3 insertions(+), 1 deletion(-) diff --git a/archivebox/core/urls.py b/archivebox/core/urls.py index 1520710c..8746083d 100644 --- a/archivebox/core/urls.py +++ b/archivebox/core/urls.py @@ -12,6 +12,8 @@ from config import VERSION, VERSION_RELEASES, CAN_UPGRADE # print('DEBUG', settings.DEBUG) +GLOBAL_CONTEXT = {'VERSION': VERSION, 'VERSIONS_AVAILABLE': VERSIONS_AVAILABLE, 'CAN_UPGRADE': CAN_UPGRADE} + urlpatterns = [ path('public/', PublicIndexView.as_view(), name='public-index'), @@ -31,7 +33,7 @@ urlpatterns = [ path('accounts/', include('django.contrib.auth.urls')), - path('admin/', admin.site.urls, {'extra_context': {'VERSION': VERSION, 'VERSION_RELEASES': VERSION_RELEASES, 'CAN_UPGRADE': CAN_UPGRADE}}), + path('admin/', admin.site.urls, {'extra_context': GLOBAL_CONTEXT}), path('health/', HealthCheckView.as_view(), name='healthcheck'), path('error/', lambda _: 1/0),