Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

User#can_edit? fix #5976

Open
wants to merge 2 commits into
base: master
Choose a base branch
from

Conversation

TunrayoIlawole
Copy link

What this PR does

This PR addresses #5948 by ensuring users with multiple roles are correctly assigned editing permissions.

More details on what was done

  • Updated User#role method to properly handle cases where a user has multiple roles in a course.
  • The method now checks if the user has any editing role and returns the appropriate role.
  • Added unit test to verify that users with both campus volunteer (non-editing role) and instructor roles are correctly recognized as having editing privileges.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

1 participant