-
Bug
-
Resolution: Fixed
-
Minor
-
3.2.5, 3.3.2, 3.4
-
MOODLE_32_STABLE, MOODLE_33_STABLE, MOODLE_34_STABLE
-
MOODLE_32_STABLE, MOODLE_33_STABLE
-
When using the save_attempt or process_attempt web service for the quiz activity an E_WARNING is generated similar to:
E_WARNING: Creating default object from empty value |
in quiz_attempt::set_offline_modified_time called at /var/www/html/mod/quiz/attemptlib.php (2336)in quiz_attempt::set_offline_modified_time called at /var/www/html/mod/quiz/classes/external.php (1249)in mod_quiz_external::process_attempt called at ? (?)in call_user_func_array called at /var/www/html/webservice/lib.php (1353)in webservice_base_server::execute called at /var/www/html/webservice/lib.php (1217)in webservice_base_server::run called at /var/www/html/webservice/rest/server.php (44) |
It is caused by this code:
// Update the timemodifiedoffline field only if web services are being used.
|
if (WS_SERVER) { |
$attemptobj->attempt->timemodifiedoffline = $time;
|
}
|