fix off-by-one, and fix link

The link was broken if the inserted dir was not under the destpage
master
Joey Hess 2008-08-23 12:37:19 -04:00
parent 15a0a151bf
commit d23943ebea
1 changed files with 2 additions and 2 deletions

View File

@ -113,11 +113,11 @@ sub preprocess (@) { #{{{
}
if ($depth > $indent) {
my $p="";
$p.="/".shift(@bits) for 1..$indent+1;
$p.="/".shift(@bits) for 1..$indent;
$p=~s/^\///;
$map .= "<li>"
.htmllink($params{page}, $params{destpage},
$p, class => "mapparent",
"/".$common_prefix."/".$p, class => "mapparent",
noimageinline => 1)
."\n";
$openli=1;