diff options
author | Yaroslav de la Peña <contact@yaroslavps.com> | 2018-07-19 22:52:35 +0300 |
---|---|---|
committer | Yaroslav de la Peña <contact@yaroslavps.com> | 2018-07-19 22:52:35 +0300 |
commit | f08af5db27fcda1d3b3bd7d176ace2141488b6ac (patch) | |
tree | c80d67bc88813a6f8a4f97d5fb7e7a07ace1abe5 /weblog/views.py | |
parent | adb87583cc63ca228a6492dc641f3e1389edc629 (diff) | |
download | w3blog-f08af5db27fcda1d3b3bd7d176ace2141488b6ac.tar.gz w3blog-f08af5db27fcda1d3b3bd7d176ace2141488b6ac.zip |
bug fix, deprecated is_authenticated() not compatible with django 2.0
Diffstat (limited to 'weblog/views.py')
-rwxr-xr-x | weblog/views.py | 2 |
1 files changed, 1 insertions, 1 deletions
diff --git a/weblog/views.py b/weblog/views.py index 03de5a7..fe050a4 100755 --- a/weblog/views.py +++ b/weblog/views.py @@ -212,7 +212,7 @@ def PostView(request, category_slug, post_slug, language=None): comment_content = form.cleaned_data['content'] # Make sure that either anonymous comments are allowed or # that the user is authenticated - if request.user.is_authenticated(): + if request.user.is_authenticated: new_comment = PostComment(author=request.user, post=post, content=comment_content) new_comment.save() elif ALLOW_ANON_COMMENTS: |