Minor - format code

pull/3837/head
Julio Montoya 5 years ago
parent 3bafa35cd6
commit 285bf530ec
  1. 2
      main/exercise/exercise.class.php
  2. 3
      main/exercise/exercise_admin.php
  3. 5
      main/inc/lib/usergroup.lib.php

@ -4609,7 +4609,7 @@ class Exercise
$questionScore += $i_answerWeighting;
$totalScore += $i_answerWeighting;
$user_answer = Display::label(get_lang('Correct'), 'success');
if ($this->showExpectedChoice() &&!empty($i_answer_id_auto)) {
if ($this->showExpectedChoice() && !empty($i_answer_id_auto)) {
$user_answer = $answerMatching[$i_answer_id_auto];
}
$status = Display::label(get_lang('Correct'), 'success');

@ -196,7 +196,8 @@ if ($form->validate()) {
$lp_id = $_GET['lp_id'];
}
$lp_id = (int) $lp_id;
echo "<a href=\"../lp/lp_controller.php?".api_get_cidreq()."&gradebook=&action=add_item&type=step&lp_id=".$lp_id."#resource_tab-2\">".
echo "<a
href=\"../lp/lp_controller.php?".api_get_cidreq()."&gradebook=&action=add_item&type=step&lp_id=".$lp_id."#resource_tab-2\">".
Display::return_icon('back.png', get_lang("BackTo").' '.get_lang('LearningPaths'), '', ICON_SIZE_MEDIUM)."</a>";
} else {
echo '<a href="exercise.php?'.api_get_cidreq().'">'.

@ -446,7 +446,7 @@ class UserGroup extends Model
* Gets all users that are part of a group or class.
*
* @param array $options
* @param int $type 0 = classes / 1 = social groups
* @param int $type 0 = classes / 1 = social groups
*
* @return array
*/
@ -520,7 +520,8 @@ class UserGroup extends Model
if ($getCount) {
if (Database::num_rows($result)) {
$row = Database::fetch_array($result);
return $row['count'];
return (int) $row['count'];
}
return 0;

Loading…
Cancel
Save