From d65c238b2c162d44812e09de2c0b1ffade3fcf41 Mon Sep 17 00:00:00 2001 From: tjhunt Date: Thu, 15 Jan 2009 05:15:38 +0000 Subject: [PATCH] question engine: MDL-17651 this context is not used anywhere, so remove it. (There was a bug in the get_context_instance call.) --- question/type/questiontype.php | 9 --------- 1 file changed, 9 deletions(-) diff --git a/question/type/questiontype.php b/question/type/questiontype.php index b0ead0faa3..9785f71ab0 100644 --- a/question/type/questiontype.php +++ b/question/type/questiontype.php @@ -902,15 +902,6 @@ class default_questiontype { global $CFG; $isgraded = question_state_is_graded($state->last_graded); - // Get the context we should use to check permissions. - if (!empty($cmoptions->id)) { - $context = get_context_instance(CONTEXT_MODULE, $cmoptions->id); - } else if (!empty($cmoptions->course)) { - $context = get_context_instance(CONTEXT_COURSE, $cmoptions->course); - } else { - $context = null; - } - if (isset($question->randomquestionid)) { $actualquestionid = $question->randomquestionid; } else { -- 2.39.5