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

matthew lon-capa-cvs@mail.lon-capa.org
Fri, 20 Feb 2004 17:13:04 -0000


matthew		Fri Feb 20 12:13:04 2004 EDT

  Modified files:              
    /loncom/interface	loncommon.pm 
  Log:
  &bodytag: Best to keep prior behavior and change the value of $function if 
  it does not evaluate to true instead of it simply not being undef.
  
  
Index: loncom/interface/loncommon.pm
diff -u loncom/interface/loncommon.pm:1.182 loncom/interface/loncommon.pm:1.183
--- loncom/interface/loncommon.pm:1.182	Fri Feb 20 12:03:38 2004
+++ loncom/interface/loncommon.pm	Fri Feb 20 12:13:04 2004
@@ -1,7 +1,7 @@
 # The LearningOnline Network with CAPA
 # a pile of common routines
 #
-# $Id: loncommon.pm,v 1.182 2004/02/20 17:03:38 matthew Exp $
+# $Id: loncommon.pm,v 1.183 2004/02/20 17:13:04 matthew Exp $
 #
 # Copyright Michigan State University Board of Trustees
 #
@@ -2359,7 +2359,7 @@
 sub bodytag {
     my ($title,$function,$addentries,$bodyonly,$domain,$forcereg)=@_;
     $title=&mt($title);
-    $function = &get_users_function() if (! defined($function));
+    $function = &get_users_function() if (!$function);
     my $img=&designparm($function.'.img',$domain);
     my $pgbg=&designparm($function.'.pgbg',$domain);
     my $tabbg=&designparm($function.'.tabbg',$domain);