Skip to content

HTTPS clone URL

Subversion checkout URL

You can clone with
or
.
Download ZIP
Browse files

NOBUG proper checking the value of checkbox elements

Without this patch, PHP generates notices as the variables representing
unchecked checkboxes are not defined at all in $data object.
  • Loading branch information...
commit c17e376337c1fd715d58f9294d615c1ae04fe6b8 1 parent d57599c
@mudrd8mz mudrd8mz authored
Showing with 2 additions and 2 deletions.
  1. +2 −2 course/edit.php
View
4 course/edit.php
@@ -84,11 +84,11 @@
/// process data if submitted
//preprocess data
- if ($data->enrolstartdisabled){
+ if (!empty($data->enrolstartdisabled)) {
$data->enrolstartdate = 0;
}
- if ($data->enrolenddisabled) {
+ if (!empty($data->enrolenddisabled)) {
$data->enrolenddate = 0;
}
Please sign in to comment.
Something went wrong with that request. Please try again.