Details
-
Bug
-
Status: Closed
-
Minor
-
Resolution: Fixed
-
1.9, 1.9.1, 1.9.2
-
None
-
MOODLE_19_STABLE
-
MOODLE_19_STABLE
Description
When you first create a course, you have the opportunity to rename the roles. Any entries you make are ignored. New role names are only applied when you update an existing course.
Steps to reproduce:
1. Go to /course/edit.php and create a new course
2. Rename some of the roles
3. Submit the form
Expected result:
Redirect to /admin/roles/assign.php, which lists the roles with their new names, and the old names in brackets.
Actual result:
Redirect to /admin/roles/assign.php with only the default role names displayed.
This is because create_course() in /course/lib.php lacks the code to handle role renaming. It does exist in update_course(), so I copied it from there (with some minor modifications). Please see the attached patch.