今天用Flask-Login时,遇到了一个问题,显示为:
{%if current_user.is_authenticated()%} 'bool' object has no attribute 'call'
查找了解决方案为:
current_user.is_authenticated" instead of "current_user.is_authenticated()"
但是不知道为什么这么做就没问题。
具体连接为:
https://github.com/lingthio/Flask-User-starter-app/issues/9
记录问题,以后明白了再来补充答案。
Flask之 bool object has no attribute '__call__'问题
最后编辑于 :
©著作权归作者所有,转载或内容合作请联系作者
平台声明:文章内容(如有图片或视频亦包括在内)由作者上传并发布,文章内容仅代表作者本人观点,简书系信息发布平台,仅提供信息存储服务。
平台声明:文章内容(如有图片或视频亦包括在内)由作者上传并发布,文章内容仅代表作者本人观点,简书系信息发布平台,仅提供信息存储服务。
推荐阅读更多精彩内容
- 22年12月更新:个人网站关停,如果仍旧对旧教程有兴趣参考 Github 的markdown内容[https://...
- 最近在学习flask,用到flask-login,发现网上只有0.1版本的中文文档,看了官方已经0.4了,并且添加...
- Correctness AdapterViewChildren Summary: AdapterViews can...
- Quickstart http://flask.pocoo.org/docs/0.12/quickstart/ Q...