Skip to content

Commit

Permalink
pycodestyle
Browse files Browse the repository at this point in the history
  • Loading branch information
mikeseibel committed Dec 10, 2024
1 parent dec3e20 commit 88af814
Showing 1 changed file with 5 additions and 3 deletions.
8 changes: 5 additions & 3 deletions blti/roles.py
Original file line number Diff line number Diff line change
Expand Up @@ -5,16 +5,18 @@
LTI_1p3_ROLES_CLAIM = "https://purl.imsglobal.org/spec/lti/claim/roles"
LTI_1p3_ROLE_PREFIX = "http://purl.imsglobal.org/vocab/lis/v2/"


def roles_from_role_name(role_names):
roles = []

for role_name in role_names:
if role_name == 'User':
roles += ["system/person#User"]
elif role_name in ['Observer', 'Mentor']:
roles += ["institution/person#Observer",
"institution/person#Mentor",
"membership#Mentor"]
roles += [
"institution/person#Observer",
"institution/person#Mentor",
"membership#Mentor"]
elif role_name in ['Student', 'Learner']:
roles += [
"institution/person#Learner",
Expand Down

0 comments on commit 88af814

Please sign in to comment.