Skip to content

Commit

Permalink
fix lint errors
Browse files Browse the repository at this point in the history
  • Loading branch information
ginsstaahh committed Feb 5, 2019
1 parent 6a3c1d0 commit ae9dc99
Showing 1 changed file with 9 additions and 1 deletion.
10 changes: 9 additions & 1 deletion bounce/db/club.py
Original file line number Diff line number Diff line change
Expand Up @@ -50,6 +50,10 @@ def to_dict(self):


def can_delete(editor_role):
"""
Determines whether a member can delete a club
given his role
"""
# Only President can delete club
if editor_role == Roles.president.value:
return True
Expand All @@ -58,11 +62,15 @@ def can_delete(editor_role):


def can_update(editor_role):
"""
Determines whether a member can update a club
given his role
"""
# President and Admin can update club
if editor_role == Roles.president.value or editor_role == Roles.admin.value:
return True
# Return false if the condition is not met
return False
return False


def validate_club(session, club_name):
Expand Down

0 comments on commit ae9dc99

Please sign in to comment.