diff options
Diffstat (limited to 'commentingapp/views.py')
-rw-r--r-- | commentingapp/views.py | 6 |
1 files changed, 1 insertions, 5 deletions
diff --git a/commentingapp/views.py b/commentingapp/views.py index f2a0f36..a97fc07 100644 --- a/commentingapp/views.py +++ b/commentingapp/views.py @@ -2,17 +2,13 @@ from django.shortcuts import render, render_to_response from django.contrib.auth.decorators import login_required from django.template import RequestContext from .models import Url, Comments -from django.contrib.auth.decorators import user_passes_test from django.db.models import Q -from django.contrib.auth.models import User from collections import Counter -import os.path -from email.mime.text import MIMEText from django.http import Http404 from tbc.models import Book, Chapters from tbc.views import is_reviewer -@user_passes_test(lambda u:u.is_superuser, login_url="/admin/login/") +@login_required(login_url="/login/") def commenting(request): ci = RequestContext(request) |