From 50d08bc2aea1d8d52e07ae1750e73b722bd2db24 Mon Sep 17 00:00:00 2001 From: Joey Hess Date: Thu, 15 Apr 2010 18:18:48 -0400 Subject: [PATCH] conditional: Fix bug that forced "all" mode off by default. Commit b7351daacd0d4a041a51b43d99b7bf589de54f53 introduced the bug. --- IkiWiki/Plugin/conditional.pm | 2 +- debian/changelog | 1 + 2 files changed, 2 insertions(+), 1 deletion(-) diff --git a/IkiWiki/Plugin/conditional.pm b/IkiWiki/Plugin/conditional.pm index 892b1cff9..8a5796149 100644 --- a/IkiWiki/Plugin/conditional.pm +++ b/IkiWiki/Plugin/conditional.pm @@ -30,7 +30,7 @@ sub preprocess_if (@) { } my $result=0; - if (! IkiWiki::yesno($params{all}) || + if ((exists $params{all} && ! IkiWiki::yesno($params{all})) || # An optimisation to avoid needless looping over every page # for simple uses of some of the tests. $params{test} =~ /^([\s\!()]*((enabled|sourcepage|destpage|included)\([^)]*\)|(and|or))[\s\!()]*)+$/) { diff --git a/debian/changelog b/debian/changelog index c379253d7..dfb94ae22 100644 --- a/debian/changelog +++ b/debian/changelog @@ -41,6 +41,7 @@ ikiwiki (3.20100415) UNRELEASED; urgency=low shown on a page. * Enable calendar and sidebar in auto-blog.setup. * sidebar: Add global_sidebars setting. + * conditional: Fix bug that forced "all" mode off by default. -- Joey Hess Sun, 04 Apr 2010 12:17:11 -0400 -- 2.26.2