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

raeburn raeburn at source.lon-capa.org
Thu Dec 11 08:15:36 EST 2014


raeburn		Thu Dec 11 13:15:36 2014 EDT

  Modified files:              
    /loncom/interface	lonnotify.pm 
  Log:
  - Coding style: sort() keys()
  
  
Index: loncom/interface/lonnotify.pm
diff -u loncom/interface/lonnotify.pm:1.40 loncom/interface/lonnotify.pm:1.41
--- loncom/interface/lonnotify.pm:1.40	Thu Jan 16 18:07:45 2014
+++ loncom/interface/lonnotify.pm	Thu Dec 11 13:15:35 2014
@@ -1,7 +1,7 @@
 # The LearningOnline Network with CAPA
 # Sending messages
 #
-# $Id: lonnotify.pm,v 1.40 2014/01/16 18:07:45 bisitz Exp $
+# $Id: lonnotify.pm,v 1.41 2014/12/11 13:15:35 raeburn Exp $
 #
 # Copyright Michigan State University Board of Trustees
 #
@@ -220,8 +220,8 @@
     $output .= &Apache::lonhtmlcommon::row_title(&mt('Choose sender(s)'));
     my %personnel = &Apache::lonnet::get_domain_roles($cdom,\@roles);
     my @domcc = ();
-    foreach my $server (keys %personnel) {
-        foreach my $user (sort(keys %{$personnel{$server}})) {
+    foreach my $server (keys(%personnel)) {
+        foreach my $user (sort(keys(%{$personnel{$server}}))) {
             my ($trole,$uname,$udom,$runame,$rudom,$rsec) = split(/:/,$user);
             unless (grep/^$uname:$udom$/, at domcc) {
                 my %userinfo = &Apache::lonnet::get('environment',['lastname','firstname'],$udom,$uname);
@@ -645,7 +645,7 @@
         $output .= &Apache::loncommon::end_data_table();
         if (@unmatched) {
             $output .= '<br /><br />'.&mt('Could not determine e-mail addresses for the following users:').'<ul>';
-            foreach my $username (sort @unmatched) {
+            foreach my $username (sort(@unmatched)) {
                 $output .= '<li>'.$username.'</li>';
             }
             $output .= '</ul>';




More information about the LON-CAPA-cvs mailing list