Skip to content

HTTPS clone URL

Subversion checkout URL

You can clone with
or
.
Download ZIP
Browse files

MDL-34050 Lesson Module: Fixed spacing and removed array_unique() for…

… responses
  • Loading branch information...
commit b0ff0e9aae2d14780ac125bd1bd29a56dc94a378 1 parent 2e48a42
@rwijaya rwijaya authored
Showing with 2 additions and 3 deletions.
  1. +2 −2 mod/lesson/locallib.php
  2. +0 −1  mod/lesson/pagetypes/matching.php
View
4 mod/lesson/locallib.php
@@ -2311,9 +2311,9 @@ public function properties() {
$count = 0;
$qtype = $properties->qtype;
foreach ($this->answers as $answer) {
- $properties->{'answer_editor['.$count.']'} = array('text'=>$answer->answer, 'format'=>$answer->answerformat);
+ $properties->{'answer_editor['.$count.']'} = array('text' => $answer->answer, 'format' => $answer->answerformat);
if ($qtype != LESSON_PAGE_MATCHING) {
- $properties->{'response_editor['.$count.']'} = array('text'=>$answer->response, 'format'=>$answer->responseformat);
+ $properties->{'response_editor['.$count.']'} = array('text' => $answer->response, 'format' => $answer->responseformat);
} else {
$properties->{'response_editor['.$count.']'} = $answer->response;
}
View
1  mod/lesson/pagetypes/matching.php
@@ -80,7 +80,6 @@ protected function make_answer_form($attempt=null) {
if (!empty($responses)) {
$shuffleresponses = $responses;
shuffle($shuffleresponses);
- $shuffleresponses = array_unique($shuffleresponses);
foreach ($shuffleresponses as $response) {
$key = array_search($response, $responses);
$responseoptions[$key] = $response;
Please sign in to comment.
Something went wrong with that request. Please try again.