Only add 'Anmelden' item to nav if user is not authenticated
This commit is contained in:
parent
77bbca4d37
commit
d4fdc952aa
|
@ -45,6 +45,9 @@ def populate_app_nav(sender, **kwargs):
|
||||||
request = sender
|
request = sender
|
||||||
nav_items = []
|
nav_items = []
|
||||||
|
|
||||||
|
if request.user.is_authenticated:
|
||||||
|
return nav_items
|
||||||
|
|
||||||
helper = request.helper
|
helper = request.helper
|
||||||
if helper is None:
|
if helper is None:
|
||||||
nav_items.append({"link": reverse("register"), "text": "Anmelden"})
|
nav_items.append({"link": reverse("register"), "text": "Anmelden"})
|
||||||
|
|
Loading…
Reference in New Issue