--- loncom/lonnet/perl/lonnet.pm 2004/01/31 01:03:56 1.469 +++ loncom/lonnet/perl/lonnet.pm 2004/02/02 20:21:25 1.470 @@ -1,7 +1,7 @@ # The LearningOnline Network # TCP networking package # -# $Id: lonnet.pm,v 1.469 2004/01/31 01:03:56 www Exp $ +# $Id: lonnet.pm,v 1.470 2004/02/02 20:21:25 www Exp $ # # Copyright Michigan State University Board of Trustees # @@ -1436,6 +1436,10 @@ sub get_course_adv_roles { my $cid=shift; $cid=$ENV{'request.course.id'} unless (defined($cid)); my %coursehash=&coursedescription($cid); + my %nothide=(); + foreach (split(/\s*\,\s*/,$coursehash{'nothideprivileged'})) { + $nothide{join(':',split(/[\@\:]/,$_))}=1; + } my %returnhash=(); my %dumphash= &dump('nohist_userroles',$coursehash{'domain'},$coursehash{'num'}); @@ -1446,7 +1450,8 @@ sub get_course_adv_roles { if (($tend) && ($tend<$now)) { next; } if (($tstart) && ($now<$tstart)) { next; } my ($role,$username,$domain,$section)=split(/\:/,$_); - if (&privileged($username,$domain)) { next; } + if ((&privileged($username,$domain)) && + (!$nothide{$username.':'.$domain})) { next; } my $key=&plaintext($role); if ($section) { $key.=' (Sec/Grp '.$section.')'; } if ($returnhash{$key}) {