Prevent updating the user role for LTI launches

This commit is contained in:
Sebastian Serth
2020-02-02 12:35:24 +01:00
parent fb21d7d9c1
commit d977039699

View File

@ -155,7 +155,7 @@ module Lti
internal_role = @current_user.role internal_role = @current_user.role
internal_role != 'admin' ? desired_role = external_role : desired_role = internal_role internal_role != 'admin' ? desired_role = external_role : desired_role = internal_role
# Update user with new information but change the role only if he is no admin user # Update user with new information but change the role only if he is no admin user
@current_user.update(email: external_user_email(@provider), name: external_user_name(@provider), role: desired_role) @current_user.update(email: external_user_email(@provider), name: external_user_name(@provider))# TODO , role: desired_role)
end end
private :set_current_user private :set_current_user