conditional: Fix bug that forced "all" mode off by default.
authorJoey Hess <joey@gnu.kitenet.net>
Thu, 15 Apr 2010 22:18:48 +0000 (18:18 -0400)
committerJoey Hess <joey@gnu.kitenet.net>
Thu, 15 Apr 2010 22:18:48 +0000 (18:18 -0400)
Commit b7351daacd0d4a041a51b43d99b7bf589de54f53 introduced the bug.

IkiWiki/Plugin/conditional.pm
debian/changelog

index 892b1cff9e1d9958f19c9916f805415442cbce41..8a57961491942438864c87a6ff1662b7d60a6439 100644 (file)
@@ -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\!()]*)+$/) {
index c379253d7e38eb6a98be4f384e93ec540847dd60..dfb94ae225be12f2f81c0192fd8939e67785d265 100644 (file)
@@ -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 <joeyh@debian.org>  Sun, 04 Apr 2010 12:17:11 -0400