Moved the postscan hook to run on the raw html of a page, before the template is...
[ikiwiki.git] / IkiWiki / Render.pm
index 0889fed6218aa79e551b3656c2a93ba9607c9d69..ab3a71671455874a0b8032bfd8d09f5b362339aa 100644 (file)
@@ -61,6 +61,10 @@ sub backlinks ($) {
 sub genpage ($$) {
        my $page=shift;
        my $content=shift;
+       
+       run_hooks(postscan => sub {
+               shift->(page => $page, content => $content);
+       });
 
        my $templatefile;
        run_hooks(templatefile => sub {
@@ -130,10 +134,6 @@ sub genpage ($$) {
        
        $content=$template->output;
        
-       run_hooks(postscan => sub {
-               shift->(page => $page, content => $content);
-       });
-
        run_hooks(format => sub {
                $content=shift->(
                        page => $page,