mirror of
https://github.com/minetest/contentdb.git
synced 2024-11-10 09:33:44 +01:00
Fix crash on email templating
This commit is contained in:
parent
31f52580c2
commit
6503a82094
@ -16,7 +16,7 @@ def inject_functions():
|
||||
@app.context_processor
|
||||
def inject_todo():
|
||||
todo_list_count = None
|
||||
if current_user.is_authenticated and current_user.canAccessTodoList():
|
||||
if current_user and current_user.is_authenticated and current_user.canAccessTodoList():
|
||||
todo_list_count = Package.query.filter_by(state=PackageState.READY_FOR_REVIEW).count()
|
||||
todo_list_count += PackageRelease.query.filter_by(approved=False, task_id=None).count()
|
||||
|
||||
|
Loading…
Reference in New Issue
Block a user