Skip to content

Commit

Permalink
fix undefined property "cr_timefinish", when viewing click report
Browse files Browse the repository at this point in the history
  • Loading branch information
gbateson committed Dec 8, 2006
1 parent acf2052 commit 4db2e65
Showing 1 changed file with 8 additions and 3 deletions.
11 changes: 8 additions & 3 deletions mod/hotpot/report.php
Original file line number Diff line number Diff line change
Expand Up @@ -259,9 +259,14 @@

$users[$userid]->attempts[] = &$attempts[$id];

if ($mode=='click' && isset($cr_attempts[$id])) {
$attempts[$id]->cr_lastclick = $cr_attempts[$id]->id;
$attempts[$id]->cr_timefinish = $cr_attempts[$id]->timefinish;
if ($mode=='click') {
// shortcut to clickreportid (=the id of the FIRST attempt in this clickreport series)
$clickreportid = $attempt->clickreportid;
if (isset($cr_attempts[$clickreportid])) {
// store id and finish time of LAST attempt in this clickreport series
$attempts[$id]->cr_lastclick = $cr_attempts[$clickreportid]->id;
$attempts[$id]->cr_timefinish = $cr_attempts[$clickreportid]->timefinish;
}
}
}

Expand Down

0 comments on commit 4db2e65

Please sign in to comment.