您的位置:首页 > 移动开发 > Objective-C

AttributeError: 'bool' object has no attribute '__call__'

2017-03-27 15:41 495 查看
第八章

错误提示

attributeerror bool object has no attribute call


原因:

Flask-Login自0.3.0版本之后,is_authenticated、is_active和is_anonymous由原来的method更改为property,不可再调用。

解决方法:



{% if current_user.is_authenticated() %}


改成

{% if current_user.is_authenticated %}
内容来自用户分享和网络整理,不保证内容的准确性,如有侵权内容,可联系管理员处理 点击这里给我发消息
标签:  error