forms.py 文件源码

python
阅读 16 收藏 0 点赞 0 评论 0

项目:django-url-locks 作者: natgeosociety 项目源码 文件源码
def authenticate(self, token_value):
        """Check that the password is valid.

        This allows for revoking of a user's preview rights by changing the
        valid passwords.
        """
        try:
            backend_path, user_id = token_value.split(':', 1)
        except (ValueError, AttributeError):
            return False
        backend = auth.load_backend(backend_path)
        return bool(backend.get_user(user_id))
评论列表
文章目录


问题


面经


文章

微信
公众号

扫码关注公众号