MDL-21432 backup - my fault, fixing wrong var
authorEloy Lafuente <stronk7@moodle.org>
Fri, 6 Aug 2010 22:23:18 +0000 (22:23 +0000)
committerEloy Lafuente <stronk7@moodle.org>
Fri, 6 Aug 2010 22:23:18 +0000 (22:23 +0000)
backup/moodle2/restore_stepslib.php

index a5efc24..d11c0d4 100644 (file)
@@ -937,7 +937,7 @@ class restore_activity_grades_structure_step extends restore_structure_step {
         // This needs to be fixed in some way (outcomes & activities with multiple items)
         // $data->idnumber     = get_coursemodule_from_instance($data->itemmodule, $data->iteminstance)->idnumber;
         // In any case, verify always for uniqueness
-        $data->idnumber = grade_verify_idnumber($idnumber, $this->get_courseid()) ? $data->idnumber : null;
+        $data->idnumber = grade_verify_idnumber($data->idnumber, $this->get_courseid()) ? $data->idnumber : null;
         $data->scaleid      = $this->get_mappingid('scale', $data->scaleid);
         $data->outcomeid    = $this->get_mappingid('outcome', $data->outcomeid);
         $data->timecreated  = $this->apply_date_offset($data->timecreated);