]> git.vanrenterghem.biz Git - git.ikiwiki.info.git/blobdiff - IkiWiki/Plugin/htmlscrubber.pm
don't add actions if all empty
[git.ikiwiki.info.git] / IkiWiki / Plugin / htmlscrubber.pm
index 41cf6c991c868bb95c3a1bc74dbfbad4e3cf4368..d77ab809b7f67ae0e7d3d86842e12ea06a00736b 100644 (file)
@@ -10,8 +10,9 @@ sub import { #{{{
                call => \&sanitize);
 } # }}}
 
-sub sanitize ($) { #{{{
-       return scrubber()->scrub(shift);
+sub sanitize (@) { #{{{
+       my %params=@_;
+       return scrubber()->scrub($params{content});
 } # }}}
 
 my $_scrubber;
@@ -43,7 +44,8 @@ sub scrubber { #{{{
                        selected shape size span src start summary
                        tabindex target title type usemap valign
                        value vspace width
-               }}],
+               }, "/" => 1, # emit proper <hr /> XHTML
+               }],
        );
        return $_scrubber;
 } # }}}