Browse Source

Don't save values if not numeric.

MOODLE_35_STABLE
Dan Marsden 6 years ago
parent
commit
f4a7d9fbb2
  1. 2
      defaultstatus.php

2
defaultstatus.php

@ -113,7 +113,7 @@ switch ($action) {
if ($unmarkedstatus == $id) { if ($unmarkedstatus == $id) {
$setunmarked = true; $setunmarked = true;
} }
if (!isset($studentavailability[$id])) { if (!isset($studentavailability[$id]) || !is_numeric($studentavailability[$id])) {
$studentavailability[$id] = 0; $studentavailability[$id] = 0;
} }
$errors[$id] = attendance_update_status($status, $acronym[$id], $description[$id], $grade[$id], $errors[$id] = attendance_update_status($status, $acronym[$id], $description[$id], $grade[$id],

Loading…
Cancel
Save