From 5fa9c035ec2fcb54770ebeeb59e43fa812523bf4 Mon Sep 17 00:00:00 2001 From: Denislav Davidov Date: Fri, 7 Feb 2025 10:08:09 +0000 Subject: [PATCH] fixing favico issue --- config/urls.py | 7 ++++++- 1 file changed, 6 insertions(+), 1 deletion(-) diff --git a/config/urls.py b/config/urls.py index 80dfa0f3..ed27c06f 100644 --- a/config/urls.py +++ b/config/urls.py @@ -18,7 +18,11 @@ from django.contrib import admin from django.urls import include, path from django.views.generic.base import RedirectView +from django.http import HttpResponse +from django.urls import re_path +def empty_favicon(request): + return HttpResponse(status=204) urlpatterns = [ path("auth/", include("authbroker_client.urls", namespace="authbroker")), @@ -38,6 +42,7 @@ path("payroll/", include("payroll.urls")), path("admin/", admin.site.urls), # TODO - split below out into develop only? + re_path(r"^favicon.ico$", empty_favicon), path( "assets/", RedirectView.as_view(url="/static/govuk/assets/%(asset_path)s"), @@ -58,4 +63,4 @@ urlpatterns.append( path("__debug__/", include(debug_toolbar.urls)), - ) + ) \ No newline at end of file