]> git.openstreetmap.org Git - osqa.git/commitdiff
removed semi-useless assignment of request.user to user
authormatt <matt@0cfe37f9-358a-4d5e-be75-b63607b5c754>
Wed, 12 May 2010 00:10:27 +0000 (00:10 +0000)
committermatt <matt@0cfe37f9-358a-4d5e-be75-b63607b5c754>
Wed, 12 May 2010 00:10:27 +0000 (00:10 +0000)
git-svn-id: http://svn.osqa.net/svnroot/osqa/trunk@229 0cfe37f9-358a-4d5e-be75-b63607b5c754

forum_modules/akismet/startup.py

index 5f9ab84359f6ebbec70a69cfda96c2256518941b..310468e467e9ab8f06e3d8ee4215d737cc8759be 100644 (file)
@@ -17,7 +17,6 @@ def check_spam(param, comment_type):
         if (request.POST and request.POST.get(param, None) and WORDPRESS_API_KEY) and (not request.user.is_authenticated()
              or not (request.user.is_staff and request.user.is_superuser and request.user.reputation >= REP_TO_FOR_NO_SPAM_CHECK)):
             comment = request.POST[param]
-            user = request.user
 
             data = {
                 "user_ip":request.META["REMOTE_ADDR"],
@@ -26,7 +25,7 @@ def check_spam(param, comment_type):
                 "comment":comment
             }
 
-            if user.is_authenticated():
+            if request.user.is_authenticated():
                 data.update({
                     "comment_author":request.user.username,
                     "comment_author_email":request.user.email,