From c795dc78437e562fde29d254561895dbb0a0912e Mon Sep 17 00:00:00 2001 From: tjhunt Date: Fri, 16 Jan 2009 04:24:24 +0000 Subject: [PATCH] questiontypes: MDL-17800 Fix another merge error. --- question/type/questiontype.php | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/question/type/questiontype.php b/question/type/questiontype.php index 8dbe88b592..c8f6bc7720 100644 --- a/question/type/questiontype.php +++ b/question/type/questiontype.php @@ -1701,6 +1701,7 @@ class default_questiontype { * This is used in question/restorelib.php */ function restore($old_question_id,$new_question_id,$info,$restore) { + global $DB; $status = true; $extraquestionfields = $this->extra_question_fields(); @@ -1716,7 +1717,7 @@ class default_questiontype { foreach ($extraquestionfields as $field) { $record->$field = backup_todb($recordinfo['#'][strtoupper($field)]['0']['#']); } - if (!insert_record($questionextensiontable, $record)) { + if (!$DB->insert_record($questionextensiontable, $record)) { echo "Can't insert record in $questionextensiontable when restoring " . $this->name() . ' question id ' . $question; $status = false; -- 2.39.5