]> git.mjollnir.org Git - moodle.git/commitdiff
missed one.
authordanmarsden <danmarsden>
Tue, 4 Apr 2006 23:36:13 +0000 (23:36 +0000)
committerdanmarsden <danmarsden>
Tue, 4 Apr 2006 23:36:13 +0000 (23:36 +0000)
mod/choice/lib.php

index 60588a8aab23ec9e7bc278b6634c2ebb79197424..75eca5bd09c8ef18c3d7c58a15674332d1ed57f3 100644 (file)
@@ -128,7 +128,9 @@ function choice_update_instance($choice) {
                 $option = NULL;
                 $option->text = $value;
                 $option->choiceid = $choice->id;
-                $option->maxanswers = $choice->{'newlimit'.substr($name, 9)};
+                if (isset($choice->{'newlimit'.substr($name, 9)})) {
+                    $option->maxanswers = $choice->{'newlimit'.substr($name, 9)};
+                }
                 $option->timemodified = time();
                 insert_record("choice_options", $option);                
             }