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

Restore ROLE_ASSIGNMENTS does not match backup ROLES_ASSIGNMENTS - extra S!

    XMLWordPrintable

Details

    • Bug
    • Status: Closed
    • Major
    • Resolution: Fixed
    • 1.8
    • 1.7.2, 1.8
    • Backup
    • None
    • MOODLE_18_STABLE
    • MOODLE_17_STABLE, MOODLE_18_STABLE

    Description

      Patch to fix cvs:/backup/restorelib.php - function endElementUsers

      We were getting "Trying to get property of non-object" warnings here,
      " case "ROLE":
      //We've finalized a role, get it
      $this->info->tempuser->roles[$this->info->temprole->type] = $this->info->temprole;
      "
      It turned out that the backup produces elements ROLES_ASSIGNMENTS, ROLES_OVERRIDES - extra S on 'role' not matching the DB schema. Restorelib meanwhile has both ROLE_ASSIGNMENTS and ROLES_ASSIGMENTS etc.!! The patch makes restore match backup.
      Cheers Nick

      (OU Bugzilla Bug 2532)

      Attachments

        Activity

          People

            lazyfish Yu Zhang
            nfreear Nick Freear
            Nobody Nobody
            Adrian Greeve, Jake Dallimore, Mathew May, Mihail Geshoski, Peter Dias, Sujith Haridasan
            Votes:
            0 Vote for this issue
            Watchers:
            0 Start watching this issue

            Dates

              Created:
              Updated:
              Resolved:
              30/Mar/07