]> git.mjollnir.org Git - moodle.git/commitdiff
Fixed errors in refactoring ( rev3, almost there)
authorcap2501 <cap2501>
Tue, 29 Aug 2006 02:02:45 +0000 (02:02 +0000)
committercap2501 <cap2501>
Tue, 29 Aug 2006 02:02:45 +0000 (02:02 +0000)
course/format/topics/commands.php

index 148a387eca6ba5076aed527f805d5d4b0fc0f1f2..8eeda4d4b4f22f1630898b9275e8fa22d3867b5b 100644 (file)
@@ -14,8 +14,8 @@ $instanceid = optional_param('instanceId', 0, PARAM_INT);
 $value      = optional_param('value', 0, PARAM_INT);
 $column     = optional_param('column', 0, PARAM_ALPHA);
 $id         = optional_param('id', 0, PARAM_INT);
-$summary    = optional_param('summary', '', PARAM_INT);
-$sequence   = optional_param('sequence', '', PARAM_INT);
+$summary    = optional_param('summary', '', PARAM_ALPHA);
+$sequence   = optional_param('sequence', '', PARAM_ALPHANUM);
 $visible    = optional_param('visible', 0, PARAM_INT);
 
 // Authorise the user and verify some incoming data
@@ -75,7 +75,7 @@ switch ($class) {
 
 
             case 'sequence':
-                $dataobject->sequence = $value;
+                $dataobject->sequence = $sequence;
                 if (!update_record('course_sections',$dataobject)) {
                     error('Failed to update section');
                 }