Details
-
Bug
-
Status: Open
-
Minor
-
Resolution: Unresolved
-
3.4.5, 3.5.3, 3.6
-
None
-
MOODLE_34_STABLE, MOODLE_35_STABLE, MOODLE_36_STABLE
Description
To reproduce:
- Create cohort at category level
- In a course within that category, add a Self-Enrollment instance, and set "Only cohort members" to the new cohort created in #1
- Delete cohort created in #1
- Attempt to edit Self-Enrollment instance created in #2. This will produce the following error: Exception - Call to a member function get_record() on null
Full error reporting (with debugging on):
{{Debug info: }}
Error code: generalexceptionmessage
Stack trace:
- line 779 of /enrol/self/lib.php: Error thrown
- line 52 of /enrol/editinstance_form.php: call to enrol_self_plugin->edit_instance_form()
- line 204 of /lib/formslib.php: call to enrol_instance_edit_form->definition()
- line 69 of /enrol/editinstance.php: call to moodleform->__construct()
Output buffer: <br /> <b>Notice</b>: Undefined variable: DB in <b>/var/www/html/enrol/self/lib.php</b> on line <b>779</b><br />