X-Git-Url: http://git.vanrenterghem.biz/git.ikiwiki.info.git/blobdiff_plain/ae161be8f9bbc6f93ca654eea119a651411bd02f..73f4a8835876c8cb07808367cd72d9ae972893e8:/IkiWiki/Render.pm?ds=inline diff --git a/IkiWiki/Render.pm b/IkiWiki/Render.pm index 308d60ed0..3ebb1a324 100644 --- a/IkiWiki/Render.pm +++ b/IkiWiki/Render.pm @@ -78,11 +78,14 @@ sub genpage ($$) { my $actions=0; if (length $config{cgiurl}) { - $template->param(editurl => cgiurl(do => "edit", page => $page)) - if IkiWiki->can("cgi_editpage"); - $template->param(prefsurl => cgiurl(do => "prefs")) - if exists $hooks{auth}; - $actions++; + if (IkiWiki->can("cgi_editpage")) { + $template->param(editurl => cgiurl(do => "edit", page => $page)); + $actions++; + } + if (exists $hooks{auth}) { + $template->param(prefsurl => cgiurl(do => "prefs")); + $actions++; + } } if (defined $config{historyurl} && length $config{historyurl}) { @@ -92,7 +95,7 @@ sub genpage ($$) { $actions++; } if ($config{discussion}) { - if ($page !~ /.*\/\Q$config{discussionpage}\E$/ && + if ($page !~ /.*\/\Q$config{discussionpage}\E$/i && (length $config{cgiurl} || exists $links{$page."/".$config{discussionpage}})) { $template->param(discussionlink => htmllink($page, $page, $config{discussionpage}, noimageinline => 1, forcesubpage => 1));