Default to new and empty Page Elements instead of None.

Fixes an issue when we try to acces Page.title in the template.
This commit is contained in:
2018-12-29 18:11:11 +01:00
parent bb7d4c8a08
commit 1bdce47375

View File

@@ -18,8 +18,8 @@ def content_menus(request):
:param request: a Django request object
:return: a dict with the template variables mentioned above
"""
current_page = None
current_top_page = None
current_page = models.Page()
current_top_page = models.Page()
current_path = request.path_info[1:request.path_info.rfind('.')]
# erzeuge das Top-Level Menü