Skip to content

Commit

Permalink
Course Backup: Fix process is still using the ids for the correct col…
Browse files Browse the repository at this point in the history
…umn - refs BT#19319
  • Loading branch information
cfasanando committed Nov 8, 2021
1 parent 9090375 commit 9d28df3
Showing 1 changed file with 4 additions and 3 deletions.
Expand Up @@ -2187,7 +2187,7 @@ public function restore_quiz_question($id, $idColumn = true)
Database::query($sql);
}
}
if ($old_option_ids) {
/*if ($old_option_ids) {
$new_answers = Database::select(
'iid, correct',
$table_ans,
Expand Down Expand Up @@ -2217,7 +2217,7 @@ public function restore_quiz_question($id, $idColumn = true)
false
);
}
}
}*/
} else {
if (count($question->question_options) < 3) {
$options = [1 => 'True', 2 => 'False', 3 => 'DoubtScore'];
Expand Down Expand Up @@ -2247,7 +2247,7 @@ public function restore_quiz_question($id, $idColumn = true)
Database::query($sql);
}
}

/*
foreach ($correctAnswers as $answer_id => $correct_answer) {
$params = [];
$params['correct'] = isset($new_options[$correct_answer]) ? $new_options[$correct_answer] : '';
Expand All @@ -2264,6 +2264,7 @@ public function restore_quiz_question($id, $idColumn = true)
false
);
}
*/
}
}
}
Expand Down

0 comments on commit 9d28df3

Please sign in to comment.