--- loncom/interface/courseprefs.pm 2009/05/25 22:56:34 1.5 +++ loncom/interface/courseprefs.pm 2009/09/04 21:42:38 1.7 @@ -1,7 +1,7 @@ # The LearningOnline Network with CAPA # Handler to set configuration settings for a course # -# $Id: courseprefs.pm,v 1.5 2009/05/25 22:56:34 raeburn Exp $ +# $Id: courseprefs.pm,v 1.7 2009/09/04 21:42:38 raeburn Exp $ # # Copyright Michigan State University Board of Trustees # @@ -655,7 +655,7 @@ sub process_changes { } foreach my $key (keys(%env)) { if ($key =~ /^form\.\Q$entry\E_($match_username:$match_domain)$/) { - if ($env{'form.'.$key}) { + if ($env{$key}) { my $nothide = $1; if (!grep(/^\Q$nothide\E$/,@new_nothide)) { push(@new_nothide,$nothide); @@ -1424,7 +1424,7 @@ sub assign_course_categories { } my $catwin_js; if ($hascats) { - my $alert = &mt('Use \"Save\" in the main window to save course categories'); + my $alert = &mt("Use 'Save' in the main window to save course categories"); $catwin_js = < @@ -2411,7 +2411,9 @@ sub nothidepriv_row { } } if (exists($privileged{$udom}{$uname})) { - push(@privusers,$user); + unless (grep(/^\Q$user\E$/,@privusers)) { + push(@privusers,$user); + } } } if (@privusers) { @@ -2431,8 +2433,8 @@ sub nothidepriv_row { ''. ' '. - ''. + $hideon.' value="" />'.&mt('Hidden').' '. + ''. ''; } $datatable .= '';