Skip to content
Snippets Groups Projects
Commit 4152f5e4 authored by David Baumgold's avatar David Baumgold
Browse files

Address pylint issue from diff-cover

parent 530c1632
No related merge requests found
......@@ -67,6 +67,10 @@ class Role(models.Model):
# TODO the name of this method is a little bit confusing,
# since it's one-off and doesn't handle inheritance later
def inherit_permissions(self, role):
"""
Make this role inherit permissions from the given role.
Permissions are only added, not removed. Does not handle inheritance.
"""
if role.course_id and role.course_id != self.course_id:
logging.warning(
"%s cannot inherit permissions from %s due to course_id inconsistency",
......
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment