Details
Description
the error is located in moodle\mod\scorm\datamodels\scorm_13.js.php, somewhere around theese lines
<?php
$count = 0;
$objectives = '';
foreach($userdata as $element => $value){
if (substr($element,0,14) == 'cmi.objectives') {
preg_match('/.(\d+)./',$element,$matches);
the output javascript that produces the error:
cmi.objectives..N0 = new Object();
cmi.objectives..N0.score = new Object();
cmi.objectives..N0.score._children = score_children;
the api is than broken, and the sco's cannto talk with the lms anymore.
the bug is triggered when the sco sets "cmi.objectives.0.id". the next time you will enter the course, the javascript code will generate an error, and prevent the api from initializing
Hi Piers,
can you please check this? - the commit messages suggest this may only be partially fixed in HEAD - more stable files had patches committed than the files in HEAD - haven't had a good look though - you may just be able to close this bug.
thanks!
Dan