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

When adding a new Scorm object, issues can arise if moddata contains data from a previous install.

    XMLWordPrintable

    Details

    • Type: Bug
    • Status: Closed
    • Priority: Trivial
    • Resolution: Fixed
    • Affects Version/s: 1.8, 1.9
    • Fix Version/s: 1.8.7, 1.9.3, 2.0
    • Component/s: SCORM
    • Labels:
      None
    • Affected Branches:
      MOODLE_18_STABLE, MOODLE_19_STABLE
    • Fixed Branches:
      MOODLE_18_STABLE, MOODLE_19_STABLE, MOODLE_20_STABLE

      Description

      to reproduce - create a new moodle install. create a course and add a scorm object.

      delete the database, and reinstall moodle, create a course and add a scorm object.

      "rename" fails, as it tries to rename to a folder that already exists.

      in function scorm_add_instance() for scorm/lib.php

      before this line is called:
      rename($scorm->dir.$scorm->datadir,$scorm->dir.'/'.$id);

      a check should be made to see if ($scorm->dir.'/'.$id) exists and if so delete it's contents before continuing.

        Attachments

          Activity

            People

            Assignee:
            danmarsden Dan Marsden
            Reporter:
            danmarsden Dan Marsden
            Tester:
            Piers Harding
            Participants:
            Component watchers:
            Damyon Wiese, Dan Marsden, Matteo Scaramuccia, Adrian Greeve, Jake Dallimore, Mathew May, Mihail Geshoski, Peter Dias
            Votes:
            0 Vote for this issue
            Watchers:
            0 Start watching this issue

              Dates

              Created:
              Updated:
              Resolved:
              Fix Release Date:
              15/Oct/08