Fixed #1722 -- Fixed bug in CommentManager.user_is_moderator(). Thanks, Jure Cuhalev

git-svn-id: http://code.djangoproject.com/svn/django/trunk@2848 bcc190cf-cafb-0310-a4f2-bffc1f526a37
This commit is contained in:
Adrian Holovaty 2006-05-05 12:52:15 +00:00
parent 4f15f10048
commit a0872543a7
1 changed files with 1 additions and 1 deletions

View File

@ -56,7 +56,7 @@ class CommentManager(models.Manager):
def user_is_moderator(self, user): def user_is_moderator(self, user):
if user.is_superuser: if user.is_superuser:
return True return True
for g in user.group_set.all(): for g in user.groups.all():
if g.id == settings.COMMENTS_MODERATORS_GROUP: if g.id == settings.COMMENTS_MODERATORS_GROUP:
return True return True
return False return False