]> git.vanrenterghem.biz Git - git.ikiwiki.info.git/blobdiff - IkiWiki/Plugin/inline.pm
substantially expand the mediawiki tip with some of the steps. More to come
[git.ikiwiki.info.git] / IkiWiki / Plugin / inline.pm
index 815a3783841b7b1017d82d51d754041f1be13f34..553fd350c15dd173305d52da5e9b9c2e85be332a 100644 (file)
@@ -218,7 +218,7 @@ sub preprocess_inline (@) {
 
                @list = pagespec_match_list($params{page}, $params{pages},
                        deptype => deptype($quick ? "presence" : "content"),
-                       limit => sub { $_[0] ne $params{page} },
+                       filter => sub { $_[0] eq $params{page} },
                        sort => exists $params{sort} ? $params{sort} : "age",
                        reverse => yesno($params{reverse}),
                        num => $num,
@@ -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.