[LON-CAPA-cvs] cvs: loncom /enrollment Autoupdate.pl

raeburn raeburn at source.lon-capa.org
Wed Dec 6 18:38:45 EST 2023


raeburn		Wed Dec  6 23:38:45 2023 EDT

  Modified files:              
    /loncom/enrollment	Autoupdate.pl 
  Log:
  - Remove trailing whitespace.
  
  
Index: loncom/enrollment/Autoupdate.pl
diff -u loncom/enrollment/Autoupdate.pl:1.25 loncom/enrollment/Autoupdate.pl:1.26
--- loncom/enrollment/Autoupdate.pl:1.25	Fri Jan 14 16:27:20 2022
+++ loncom/enrollment/Autoupdate.pl	Wed Dec  6 23:38:45 2023
@@ -1,7 +1,7 @@
 #!/usr/bin/perl
 #
 # Automated Userinfo update script
-# $Id: Autoupdate.pl,v 1.25 2022/01/14 16:27:20 raeburn Exp $
+# $Id: Autoupdate.pl,v 1.26 2023/12/06 23:38:45 raeburn Exp $
 #
 # Copyright Michigan State University Board of Trustees
 #
@@ -103,7 +103,7 @@
             my (@inststatuses);
             if (!$userhash{'internalname'}) {
                 if (defined($instusers{$uname})) {
-                    (my $insttypechg, at inststatuses) = 
+                    (my $insttypechg, at inststatuses) =
                        &affiliations_check(\%userhash,$instusers{$uname});
                     if ($insttypechg) {
                         my $inststatusstr = join(':',map { &escape($_) } (@inststatuses));
@@ -123,17 +123,17 @@
                                         push(@fields,$field);
                                     }
                                 }
-                            } 
+                            }
                         }
                     } else {
                         if (ref($settings->{fields}{'default'}) eq 'ARRAY') {
                             @fields = @{$settings->{fields}{'default'}};
                         }
                     }
-                    foreach my $field (@fields) { 
+                    foreach my $field (@fields) {
                         if ($userhash{$field} ne $instusers{$uname}{$field}) {
                             $changed = 1;
-                            if ($settings->{'classlists'} == 1) { 
+                            if ($settings->{'classlists'} == 1) {
                                 if ($field eq 'id') {
                                     $changes{'id'} = 1;
                                 } elsif ($field eq 'lastname' || $field eq 'firstname' || $field eq 'middlename' || $field eq 'generation') {
@@ -157,14 +157,14 @@
                             print $fh "User change: $uname:$dom; New values: 1.Name: $userupdate{'firstname'} $userupdate{'middlename'} $userupdate{'lastname'} $userupdate{'generation'}; 2. StuID: $userupdate{'id'}; 3. Email: $userupdate{'permanentemail'}.\n";
                             if ($settings->{'classlists'} == 1) {
                                 if ($changes{'id'} || $changes{'fullname'}) {
-                                    my %roleshash = 
+                                    my %roleshash =
                                         &Apache::lonnet::get_my_roles($uname,
                                                   $dom,'userroles',\@types,\@roles,\@cdoms);
                                     foreach my $item (keys(%roleshash)) {
                                         my ($cnum,$cdom,$role) = split(/:/,$item);
                                         my ($start,$end) = split(/:/,$roleshash{$item});
                                         if (&Apache::lonnet::is_course($cdom,$cnum)) {
-                                            my $result = 
+                                            my $result =
                                                 &Apache::lonuserutils::update_classlist($cdom,$cnum,$dom,$uname,\%userupdate);
                                             if ($result eq 'ok') {
                                                 print $fh "Classlist change: $uname:$dom - class -> $cnum:$cdom\n";




More information about the LON-CAPA-cvs mailing list