X-Git-Url: http://git.vanrenterghem.biz/git.ikiwiki.info.git/blobdiff_plain/bbfe1b9058f3e2b73d6c8c1f7eed80d72727d2a4..b9dc3e84a512eecf66b2b3e73be39530b588f49c:/IkiWiki/Plugin/typography.pm?ds=sidebyside diff --git a/IkiWiki/Plugin/typography.pm b/IkiWiki/Plugin/typography.pm index 6c5f06b0f..3b66ab0d0 100644 --- a/IkiWiki/Plugin/typography.pm +++ b/IkiWiki/Plugin/typography.pm @@ -4,8 +4,7 @@ package IkiWiki::Plugin::typography; use warnings; use strict; -use IkiWiki; -use Text::Typography; +use IkiWiki 2.00; sub import { #{{{ IkiWiki::hook(type => "sanitize", id => "typography", call => \&sanitize); @@ -14,6 +13,9 @@ sub import { #{{{ sub sanitize (@) { #{{{ my %params=@_; + eval q{use Text::Typography}; + return $params{content} if $@; + return Text::Typography::typography($params{content}); } # }}}