Skip to content

Commit

Permalink
Merge branch 'MDL-77749-unset-config-duration-MOODLE_400_STABLE' of h…
Browse files Browse the repository at this point in the history
  • Loading branch information
andrewnicols committed Jun 1, 2023
2 parents 38e2784 + 2d651dc commit 36ee03c
Showing 1 changed file with 2 additions and 2 deletions.
4 changes: 2 additions & 2 deletions lib/adminlib.php
Expand Up @@ -4050,13 +4050,13 @@ public function output_html($data, $query='') {
$context = (object) [
'id' => $this->get_id(),
'name' => $this->get_full_name(),
'value' => $data['v'],
'value' => $data['v'] ?? '',
'readonly' => $this->is_readonly(),
'options' => array_map(function($unit) use ($units, $data, $defaultunit) {
return [
'value' => $unit,
'name' => $units[$unit],
'selected' => ($data['v'] == 0 && $unit == $defaultunit) || $unit == $data['u']
'selected' => isset($data) && (($data['v'] == 0 && $unit == $defaultunit) || $unit == $data['u'])
];
}, array_keys($units))
];
Expand Down

0 comments on commit 36ee03c

Please sign in to comment.