diff options
author | Joey Hess <joey@gnu.kitenet.net> | 2009-10-15 16:25:43 -0400 |
---|---|---|
committer | Joey Hess <joey@gnu.kitenet.net> | 2009-10-15 16:25:43 -0400 |
commit | d0213917ad143c57f34a96c94ceaaf40122b11cf (patch) | |
tree | 7eb8f6d7bd404727eb574fbef7669f710c7beea1 /IkiWiki/Plugin/inline.pm | |
parent | 5a41e6054a7b0782069e4da08a6ab47ffb352392 (diff) |
inline: Optimize generation of archives, etc
Don't generate inlined page content if the template does not use it.
Diffstat (limited to 'IkiWiki/Plugin/inline.pm')
-rw-r--r-- | IkiWiki/Plugin/inline.pm | 3 |
1 files changed, 2 insertions, 1 deletions
diff --git a/IkiWiki/Plugin/inline.pm b/IkiWiki/Plugin/inline.pm index 0fe0bd2e1..553fd350c 100644 --- a/IkiWiki/Plugin/inline.pm +++ b/IkiWiki/Plugin/inline.pm @@ -337,7 +337,8 @@ sub preprocess_inline (@) { my $file = $pagesources{$page}; my $type = pagetype($file); if (! $raw || ($raw && ! defined $type)) { - unless ($archive && $quick) { + if (!($archive && $quick) && + $template->query(name => 'content')) { # Get the content before populating the # template, since getting the content uses # the same template if inlines are nested. |