--- loncom/interface/loncourseauthor.pm 2022/12/31 14:08:59 1.1 +++ loncom/interface/loncourseauthor.pm 2023/03/23 22:53:46 1.2 @@ -1,7 +1,7 @@ # The LearningOnline Network # Documents # -# $Id: loncourseauthor.pm,v 1.1 2022/12/31 14:08:59 raeburn Exp $ +# $Id: loncourseauthor.pm,v 1.2 2023/03/23 22:53:46 raeburn Exp $ # # Copyright Michigan State University Board of Trustees # @@ -87,7 +87,7 @@ sub handler { $is_home = 1; } } - } elsif ($role =~ m{^(ca|aa)\./($match_domain)/($match_username)$}) { + } elsif ($role =~ m{^(ca|aa)\./($match_domain)/($match_username)$}) { my ($rolecode,$audom,$auname) = ($1,$2,$3); if (exists($env{"user.role.$role"})) { my ($start,$end) = split(/\./,$env{"user.role.$role"}); @@ -139,6 +139,8 @@ sub handler { } else { push(@dirs,(sort { lc($a) cmp lc($b) } (keys(%dirhash)))); } + } elsif (($env{'form.role'} eq 'course') && ($env{'form.path'} eq '') && (!$env{'form.nonempty'})) { + push(@dirs,'/'); } my %files; if (%filehash) {