]> sipb.mit.edu Git - ikiwiki.git/commitdiff
don't add actions if all empty
authorjoey <joey@0fa5a96a-9a0e-0410-b3b2-a0fd24251071>
Mon, 28 Aug 2006 19:46:00 +0000 (19:46 +0000)
committerjoey <joey@0fa5a96a-9a0e-0410-b3b2-a0fd24251071>
Mon, 28 Aug 2006 19:46:00 +0000 (19:46 +0000)
IkiWiki/Plugin/inline.pm

index 6518be794f08f905a6bc154bc4e8080ac36143ac..724cdf315d34854d8094ffdfd2f08f32645f51a0 100644 (file)
@@ -108,11 +108,12 @@ sub preprocess_inline (@) { #{{{
                        if ($actions) {
                                my $file = $pagesources{$page};
                                my $type = pagetype($file);
-                               $template->param(have_actions => 1);
                                if ($config{discussion}) {
+                                       $template->param(have_actions => 1);
                                        $template->param(discussionlink => htmllink($page, $page, "Discussion", 1, 1));
                                }
                                if (length $config{cgiurl} && defined $type) {
+                                       $template->param(have_actions => 1);
                                        $template->param(editurl => cgiurl(do => "edit", page => $page));
                                }
                        }