CoreyMSchafer/code_snippets

current_user is undefine in "11-Blueprints"

Closed this issue · 1 comments

After using "create_app" method, I get an error :
jinja2.exceptions.UndefinedError: 'current_user' is undefined
it looks like from --> layout.html --> {% if current_user.is_authenticated %}

but as since we haven't set current_user before, I'm wondering why it happens?

I think I missed "login_manager.init_app(app)"