Unverified Commit 16e62ecc authored by Rajesh Taneja's avatar Rajesh Taneja
Browse files

MDL-55739 core_course: Check if gradepass is set and not empty

Default value of gradepass is 0.00000 and empty check
passes. But on oracle gradepass value is 0, so just
check if the field is set and that should be enough
parent 520ee366
......@@ -701,7 +701,7 @@ function get_moduleinfo_data($cm, $course) {
foreach ($items as $item) {
if (!empty($item->outcomeid)) {
$data->{'outcome_' . $item->outcomeid} = 1;
} else if (!empty($item->gradepass)) {
} else if (isset($item->gradepass)) {
$decimalpoints = $item->get_decimals();
$data->gradepass = format_float($item->gradepass, $decimalpoints);
Supports Markdown
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment