Fix page permissions and fix migration when on sqlite backend

This commit is contained in:
2017-09-17 17:35:47 +02:00
parent aa49b2d4ce
commit 12c49b285a
4 changed files with 42 additions and 8 deletions

View File

@ -893,7 +893,7 @@ class Page(models.Model):
)
def can_be_edited_by(self, user):
if self.is_club_page and self.club.can_be_edited_by(user):
if hasattr(self, 'club') and self.club.can_be_edited_by(user):
# Override normal behavior for clubs
return True
return False