Skip to content
Projects
Groups
Snippets
Help
This project
Loading...
Sign in / Register
Toggle navigation
E
edx-platform
Overview
Overview
Details
Activity
Cycle Analytics
Repository
Repository
Files
Commits
Branches
Tags
Contributors
Graph
Compare
Charts
Issues
0
Issues
0
List
Board
Labels
Milestones
Merge Requests
0
Merge Requests
0
CI / CD
CI / CD
Pipelines
Jobs
Schedules
Charts
Wiki
Wiki
Snippets
Snippets
Members
Members
Collapse sidebar
Close sidebar
Activity
Graph
Charts
Create a new issue
Jobs
Commits
Issue Boards
Open sidebar
edx
edx-platform
Commits
b6c69547
Commit
b6c69547
authored
Jul 23, 2013
by
David Baumgold
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
Check for instructor role before removing it
parent
c70bd5c9
Hide whitespace changes
Inline
Side-by-side
Showing
1 changed file
with
4 additions
and
1 deletions
+4
-1
cms/djangoapps/contentstore/views/user.py
+4
-1
No files found.
cms/djangoapps/contentstore/views/user.py
View file @
b6c69547
...
...
@@ -166,7 +166,10 @@ def course_team_user(request, org, course, name, email):
add_user_to_course_group
(
request
.
user
,
user
,
location
,
role
)
elif
role
==
"staff"
:
add_user_to_course_group
(
request
.
user
,
user
,
location
,
role
)
remove_user_from_course_group
(
request
.
user
,
user
,
location
,
"instructor"
)
# should *not* be an instructor
inst_groupname
=
get_course_groupname_for_role
(
location
,
"instructor"
)
if
any
(
g
.
name
==
inst_groupname
for
g
in
user
.
groups
.
all
()):
remove_user_from_course_group
(
request
.
user
,
user
,
location
,
"instructor"
)
return
JsonResponse
()
...
...
Write
Preview
Markdown
is supported
0%
Try again
or
attach a new file
Attach a file
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment