]> git.openstreetmap.org Git - osqa.git/commitdiff
OSQA-606, we convert the node score and the NECROMANCER_UP_VOTES setting to Integer...
authorjordan <jordan@0cfe37f9-358a-4d5e-be75-b63607b5c754>
Fri, 15 Apr 2011 13:32:30 +0000 (13:32 +0000)
committerjordan <jordan@0cfe37f9-358a-4d5e-be75-b63607b5c754>
Fri, 15 Apr 2011 13:32:30 +0000 (13:32 +0000)
git-svn-id: http://svn.osqa.net/svnroot/osqa/trunk@986 0cfe37f9-358a-4d5e-be75-b63607b5c754

forum_modules/default_badges/badges.py

index f0a893078912e6f61106b1d140e769785c582363..893d32a322457732e8acbc299d930383ef9762a1 100644 (file)
@@ -308,7 +308,7 @@ class Necromancer(AbstractBadge):
     def award_to(self, action):
         if (action.node.node_type == "answer") and (
         action.node.added_at >= (action.node.question.added_at + timedelta(days=int(settings.NECROMANCER_DIF_DAYS)))
     def award_to(self, action):
         if (action.node.node_type == "answer") and (
         action.node.added_at >= (action.node.question.added_at + timedelta(days=int(settings.NECROMANCER_DIF_DAYS)))
-        ) and (action.node.score == settings.NECROMANCER_UP_VOTES):
+        ) and (int(action.node.score) == int(settings.NECROMANCER_UP_VOTES)):
             return action.node.author
 
 class Taxonomist(AbstractBadge):
             return action.node.author
 
 class Taxonomist(AbstractBadge):