change CONTEXT_MODULE to CONTEXT_COURSE in order to fix "Invalid context creation for level 50 instance" error on "mod/hotpot/index.php" caused by get_context_instance(CONTEXT_MODULE, $course->id) in "mod/hotpot/lib.php"
This commit is contained in:
+1
-1
@@ -767,7 +767,7 @@ function hotpot_get_all_instances_in_course($modulename, $course) {
|
||||
|
||||
// cache $isteacher setting
|
||||
|
||||
$isteacher = has_capability('mod/hotpot:viewreport', get_context_instance(CONTEXT_MODULE, $course->id));
|
||||
$isteacher = has_capability('mod/hotpot:viewreport', get_context_instance(CONTEXT_COURSE, $course->id));
|
||||
|
||||
$explodesection = array();
|
||||
$order = array();
|
||||
|
||||
Reference in New Issue
Block a user