charactes are not people, fix changing password

This commit is contained in:
j 2011-10-22 22:12:56 +00:00
commit ea52870db6
8 changed files with 18 additions and 14 deletions

View file

@ -190,7 +190,8 @@ class Item(models.Model):
def editable(self, user):
if user.is_anonymous():
return False
if user.is_staff or \
if user.get_profile().capability('canEditMetadata') == True or \
user.is_staff or \
self.user == user or \
self.groups.filter(id__in=user.groups.all()).count() > 0:
return True