X-Git-Url: http://git.vanrenterghem.biz/git.ikiwiki.info.git/blobdiff_plain/402fd5e63b9888ef9f98bb667087ae0398f6ce8b..11fc28970b329334d88d3667e5b55e0d57e353ab:/IkiWiki/Plugin/inline.pm?ds=inline diff --git a/IkiWiki/Plugin/inline.pm b/IkiWiki/Plugin/inline.pm index 553fd350c..942df6f89 100644 --- a/IkiWiki/Plugin/inline.pm +++ b/IkiWiki/Plugin/inline.pm @@ -332,13 +332,13 @@ sub preprocess_inline (@) { error sprintf(gettext("nonexistant template %s"), $params{template}); } my $template=HTML::Template->new(@params) unless $raw; + my $needcontent=$raw || (!($archive && $quick) && $template->query(name => 'content')); foreach my $page (@list) { my $file = $pagesources{$page}; my $type = pagetype($file); if (! $raw || ($raw && ! defined $type)) { - if (!($archive && $quick) && - $template->query(name => 'content')) { + if ($needcontent) { # Get the content before populating the # template, since getting the content uses # the same template if inlines are nested.