[LON-CAPA-cvs] cvs: loncom /interface lonparmset.pm

www lon-capa-cvs@mail.lon-capa.org
Mon, 14 Nov 2005 14:01:55 -0000


www		Mon Nov 14 09:01:55 2005 EDT

  Modified files:              
    /loncom/interface	lonparmset.pm 
  Log:
  Deleting a parameter should not automatically set anything
  (particularly not dates sometime in 1970 ...).
  
  
Index: loncom/interface/lonparmset.pm
diff -u loncom/interface/lonparmset.pm:1.265 loncom/interface/lonparmset.pm:1.266
--- loncom/interface/lonparmset.pm:1.265	Fri Nov 11 18:07:27 2005
+++ loncom/interface/lonparmset.pm	Mon Nov 14 09:01:52 2005
@@ -1,7 +1,7 @@
 # The LearningOnline Network with CAPA
 # Handler to set parameters for assessments
 #
-# $Id: lonparmset.pm,v 1.265 2005/11/11 23:07:27 banghart Exp $
+# $Id: lonparmset.pm,v 1.266 2005/11/14 14:01:52 www Exp $
 #
 # Copyright Michigan State University Board of Trustees
 #
@@ -316,6 +316,8 @@
 # store parameter
     &storeparm_by_symb_inner
 	($symb,$spnam,$snum,$nval,$ntype,$uname,$udom,$csec);
+# don't do anything if parameter was reset
+    unless ($nval) { return; }
     my ($prefix,$parm)=($spnam=~/^(.*[\_\.])([^\_\.]+)$/);
 # remember that this was set
     $recstack{$parm}=1;