diff options
Diffstat (limited to 'IkiWiki')
-rw-r--r-- | IkiWiki/Plugin/inline.pm | 4 | ||||
-rw-r--r-- | IkiWiki/Render.pm | 3 |
2 files changed, 5 insertions, 2 deletions
diff --git a/IkiWiki/Plugin/inline.pm b/IkiWiki/Plugin/inline.pm index ff1342bc1..ecae47f1a 100644 --- a/IkiWiki/Plugin/inline.pm +++ b/IkiWiki/Plugin/inline.pm @@ -157,7 +157,9 @@ sub preprocess_inline (@) { #{{{ if ($actions) { my $file = $pagesources{$page}; my $type = pagetype($file); - if ($config{discussion} && (length $config{cgiurl} || exists $links{$page."/".gettext("discussion")})) { + if ($config{discussion} && + $page !~ /.*\/discussion$/ && + (length $config{cgiurl} || exists $links{$page."/".gettext("discussion")})) { $template->param(have_actions => 1); $template->param(discussionlink => htmllink($page, $params{page}, "Discussion", 1, 1)); } diff --git a/IkiWiki/Render.pm b/IkiWiki/Render.pm index 30249b9bd..7ca9a3820 100644 --- a/IkiWiki/Render.pm +++ b/IkiWiki/Render.pm @@ -93,7 +93,8 @@ sub genpage ($$$) { #{{{ $template->param(historyurl => $u); $actions++; } - if ($config{discussion} && (length $config{cgiurl} || exists $links{$page."/".gettext("discussion")})) { + if ($config{discussion} && $page !~ /.*\/discussion$/ && + (length $config{cgiurl} || exists $links{$page."/".gettext("discussion")})) { $template->param(discussionlink => htmllink($page, $page, gettext("Discussion"), 1, 1)); $actions++; } |