Skip to content

Instantly share code, notes, and snippets.

@o-nnerb
Created May 7, 2023 13:32
Show Gist options
  • Save o-nnerb/d184bf8e54f5725a9a24b97b42f8a31a to your computer and use it in GitHub Desktop.
Save o-nnerb/d184bf8e54f5725a9a24b97b42f8a31a to your computer and use it in GitHub Desktop.
# Check if a user has an "admin" type
def check_admin_permission(user):
if user.type == 'admin':
return True
else:
return False
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment