mirror of
https://github.com/moodle/moodle.git
synced 2025-01-19 14:27:22 +01:00
put in two !== instead of != to compare NULL values
This commit is contained in:
parent
93c865201a
commit
5805dddbb6
@ -165,7 +165,7 @@
|
||||
foreach ($tries as $try) {
|
||||
// start to build up the link
|
||||
$temp = "<a href=\"report.php?id=$cm->id&action=detail&userid=".$try["userid"]."&try=".$try["try"]."\">";
|
||||
if ($try["grade"] != NULL) { // if NULL then not done yet
|
||||
if ($try["grade"] !== NULL) { // if NULL then not done yet
|
||||
// this is what the link does when the user has completed the try
|
||||
$timetotake = $try["timeend"] - $try["timestart"];
|
||||
|
||||
@ -186,7 +186,7 @@
|
||||
$attempts[] = $temp;
|
||||
|
||||
// run these lines for the stats only if the user finnished the lesson
|
||||
if ($try["grade"] != NULL) {
|
||||
if ($try["grade"] !== NULL) {
|
||||
$numofattempts++;
|
||||
$avescore += $try["grade"];
|
||||
$avetime += $timetotake;
|
||||
|
Loading…
x
Reference in New Issue
Block a user