From a6d7ed68217b4fdf11fb0315936052c73416f89c Mon Sep 17 00:00:00 2001 From: Michael Olson Date: Sun, 23 Nov 2008 22:18:01 -0800 Subject: [PATCH] Ikiwiki plugin: Use canmeta correctly. --- examples/ikiwiki/IkiWiki/Plugin/muse.pm | 4 +++- 1 file changed, 3 insertions(+), 1 deletion(-) diff --git a/examples/ikiwiki/IkiWiki/Plugin/muse.pm b/examples/ikiwiki/IkiWiki/Plugin/muse.pm index 2949400..d30ce8c 100644 --- a/examples/ikiwiki/IkiWiki/Plugin/muse.pm +++ b/examples/ikiwiki/IkiWiki/Plugin/muse.pm @@ -53,7 +53,8 @@ sub scan (@) { pos = undef; while ( m/ \G \# ([a-zA-Z-]+) \s+ (.+?) \n+ /sgx ) { my ($key, $val) = ($1, $2); - if ( $key =~ m/^(tags?|category)$/s && $cantag ) { + if ( $key =~ m/^(tags?|category)$/s ) { + next unless $cantag; $fun = sub { IkiWiki::Plugin::tag::preprocess_tag( (map { $_ => '' } (split /\s+/, $val)), @@ -64,6 +65,7 @@ sub scan (@) { }; } else { + next unless $canmeta; if ( $key eq 'date' ) { # Support pyblosxom-style dates (YYYY-MM-DD(-hh-mm)?) my $re = qr/ ^ ([0-9]{4}) - ([0-1][0-9]) - ([0-3][0-9]) -- 2.11.4.GIT