]> sipb.mit.edu Git - ikiwiki.git/blobdiff - IkiWiki/Plugin/pagecount.pm
add postsparkline plugin, providing sparkliney stats goodness for blog
[ikiwiki.git] / IkiWiki / Plugin / pagecount.pm
index 7ced159823fff8cf8139392d9b6d81e903f3390f..313ffdff0d6e9c225957d692fbfdea6a9f3109a3 100644 (file)
@@ -1,5 +1,4 @@
 #!/usr/bin/perl
-# Provides [[pagecount ]] to count the number of pages.
 package IkiWiki::Plugin::pagecount;
 
 use warnings;
@@ -22,7 +21,7 @@ sub preprocess (@) { #{{{
        return $#pages+1 if $params{pages} eq "*"; # optimisation
        my $count=0;
        foreach my $page (@pages) {
-               $count++ if pagespec_match($page, $params{pages});
+               $count++ if pagespec_match($page, $params{pages}, $params{page});
        }
        return $count;
 } # }}}