[LON-CAPA-cvs] cvs: loncom /interface loncreatecourse.pm loncreateuser.pm lonuserutils.pm

raeburn raeburn@source.lon-capa.org
Mon, 20 Sep 2010 00:51:15 -0000


raeburn		Mon Sep 20 00:51:15 2010 EDT

  Modified files:              
    /loncom/interface	loncreateuser.pm loncreatecourse.pm 
                     	lonuserutils.pm 
  Log:
  - Prevent "Not a CODE reference." warnings.
  
  
Index: loncom/interface/loncreateuser.pm
diff -u loncom/interface/loncreateuser.pm:1.348 loncom/interface/loncreateuser.pm:1.349
--- loncom/interface/loncreateuser.pm:1.348	Tue Sep 14 06:02:35 2010
+++ loncom/interface/loncreateuser.pm	Mon Sep 20 00:51:14 2010
@@ -1,7 +1,7 @@
 # The LearningOnline Network with CAPA
 # Create a user
 #
-# $Id: loncreateuser.pm,v 1.348 2010/09/14 06:02:35 raeburn Exp $
+# $Id: loncreateuser.pm,v 1.349 2010/09/20 00:51:14 raeburn Exp $
 #
 # Copyright Michigan State University Board of Trustees
 #
@@ -3445,7 +3445,7 @@
 	}
     } # End of foreach (keys(%env))
 # Flush the course logs so reverse user roles immediately updated
-    $r->register_cleanup(\&Apache::lonnet::flushcourselogs());
+    $r->register_cleanup(\&Apache::lonnet::flushcourselogs);
     if (@rolechanges == 0) {
         $r->print(&mt('No roles to modify'));
     }
Index: loncom/interface/loncreatecourse.pm
diff -u loncom/interface/loncreatecourse.pm:1.143 loncom/interface/loncreatecourse.pm:1.144
--- loncom/interface/loncreatecourse.pm:1.143	Tue Sep 14 06:02:35 2010
+++ loncom/interface/loncreatecourse.pm	Mon Sep 20 00:51:14 2010
@@ -1,7 +1,7 @@
 # The LearningOnline Network
 # Create a course
 #
-# $Id: loncreatecourse.pm,v 1.143 2010/09/14 06:02:35 raeburn Exp $
+# $Id: loncreatecourse.pm,v 1.144 2010/09/20 00:51:14 raeburn Exp $
 #
 # Copyright Michigan State University Board of Trustees
 #
@@ -689,7 +689,7 @@
 		      '<p><a href="/adm/managekeys?cid='.$crsudom.'_'.$crsunum.'">'.&mt('Manage Access Keys').'</a></p>');
 	}
         # Flush the course logs so reverse user roles immediately updated
-	$r->register_cleanup(\&Apache::lonnet::flushcourselogs());
+	$r->register_cleanup(\&Apache::lonnet::flushcourselogs);
 	$r->print('<p>'.&mt('Roles will be active at next login').'.</p>');
     }
     $r->print('<p><a href="/adm/createcourse?phase='.lc($crstype).'one">'.
Index: loncom/interface/lonuserutils.pm
diff -u loncom/interface/lonuserutils.pm:1.125 loncom/interface/lonuserutils.pm:1.126
--- loncom/interface/lonuserutils.pm:1.125	Mon Sep 20 00:21:08 2010
+++ loncom/interface/lonuserutils.pm	Mon Sep 20 00:51:15 2010
@@ -1,7 +1,7 @@
 # The LearningOnline Network with CAPA
 # Utility functions for managing LON-CAPA user accounts
 #
-# $Id: lonuserutils.pm,v 1.125 2010/09/20 00:21:08 raeburn Exp $
+# $Id: lonuserutils.pm,v 1.126 2010/09/20 00:51:15 raeburn Exp $
 #
 # Copyright Michigan State University Board of Trustees
 #
@@ -4299,7 +4299,7 @@
             }
         } # end of foreach (@userdata)
         # Flush the course logs so reverse user roles immediately updated
-        $r->register_cleanup(\&Apache::lonnet::flushcourselogs());
+        $r->register_cleanup(\&Apache::lonnet::flushcourselogs);
         $r->print("</p>\n<p>\n".&mt('Processed [quant,_1,user].',$counts{'user'}).
                   "</p>\n");
         if ($counts{'role'} > 0) {
@@ -4791,7 +4791,7 @@
             $r->print('<p>'.&mt('Re-enabling will re-activate data for the role.').'</p>');
         }
         # Flush the course logs so reverse user roles immediately updated
-        &Apache::lonnet::flushcourselogs();
+        $r->register_cleanup(\&Apache::lonnet::flushcourselogs);
     }
     if ($env{'form.makedatesdefault'}) {
         if ($choice eq 'chgdates' || $choice eq 'reenable' || $choice eq 'activate') {