MDL-20636 Essay question type, make is_same_response consider files. #216
This commit is contained in:
@@ -2086,8 +2086,6 @@ class question_attempt {
|
||||
* behaves as if there were no files.
|
||||
*/
|
||||
protected function process_response_files($name, $postdata = null) {
|
||||
global $USER;
|
||||
|
||||
if ($postdata) {
|
||||
// There can be no files with test data (at the moment).
|
||||
return null;
|
||||
@@ -2098,13 +2096,6 @@ class question_attempt {
|
||||
return null;
|
||||
}
|
||||
|
||||
$fs = get_file_storage();
|
||||
$usercontext = get_context_instance(CONTEXT_USER, $USER->id);
|
||||
|
||||
if ($fs->is_area_empty($usercontext->id, 'user', 'draft', $draftitemid)) {
|
||||
return null;
|
||||
}
|
||||
|
||||
return new question_file_saver($draftitemid, 'question', 'response_' .
|
||||
str_replace($this->get_field_prefix(), '', $name));
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user