Uploaded image for project: 'Moodle'
  1. Moodle
  2. MDL-37091

cmi.location set to "0" gets lost when resuming

    XMLWordPrintable

Details

    • Bug
    • Status: Closed
    • Minor
    • Resolution: Won't Fix
    • 2.3
    • None
    • SCORM
    • MOODLE_23_STABLE

    Description

      If a SCORM 2004 object sets cmi.location to "0", this value gets lost when the session is resumed because scorm_13.js.php uses !empty() to test if the value has been set. empty("0") returns true.

      I've changed it to isset() instead, and that seems to work. The equivalent line in the SCORM 1.2 datamodel uses isset as well, so I'm at most as wrong as whoever wrote that line.

      It's a single-line fix, but I've got a branch at https://github.com/numbas/moodle/tree/scorm-cmi-location for easy patching.

      Attachments

        Issue Links

          Activity

            People

              danmarsden Dan Marsden
              christianp Christian Perfect
              Votes:
              0 Vote for this issue
              Watchers:
              3 Start watching this issue

              Dates

                Created:
                Updated:
                Resolved: