Commit 1eca5abb authored by IKEDA Soji's avatar IKEDA Soji
Browse files

Canonicalize help URL so that relative links in help contents will work properly.

parent 15c7f9be
......@@ -4021,6 +4021,17 @@ sub do_loginrequest {
sub do_help {
wwslog('info', '(%s)', $in{'help_topic'});
 
# Given partial top URI, redirect to base.
unless ($in{'help_topic'} or $ENV{REQUEST_URI} =~ /\/\z/) {
$param->{'redirect_to'} = Sympa::get_url(
$list, 'help',
nomenu => $param->{'nomenu'},
paths => [''], # Ends with '/'.
authority => 'local'
);
return 1;
}
$param->{'help_topic'} = $in{'help_topic'}
if $in{'help_topic'};
return 1;
......
Supports Markdown
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment