From a323901d0e3ba8f4a82ec9703554e79d4eb557e5 Mon Sep 17 00:00:00 2001 From: Christophe Siraut Date: Wed, 24 Jul 2024 10:27:42 +0200 Subject: [PATCH] templates/nav.html: logout view expects post requests --- aircox/templates/aircox/widgets/nav.html | 15 ++++++++++----- 1 file changed, 10 insertions(+), 5 deletions(-) diff --git a/aircox/templates/aircox/widgets/nav.html b/aircox/templates/aircox/widgets/nav.html index a6c7ae5..937226d 100644 --- a/aircox/templates/aircox/widgets/nav.html +++ b/aircox/templates/aircox/widgets/nav.html @@ -3,7 +3,7 @@ @@ -40,11 +40,16 @@ {% translate "Statistics" %} {% endblock %} - {% endif %} - - {% translate "Disconnect" %} - + {% if user.is_authenticated %} + +
+ {% csrf_token %} + + {% translate "Disconnect" %} + +
+ {% endif %}