X-Git-Url: https://git.mdrn.pl/fnpdjango.git/blobdiff_plain/7b2a81536977bb13b68ada3e5a281e35b24e0bfd..c4311d82afc1bb44566c6e612b09c4ecad1af643:/fnpdjango/utils/text/textilepl.py diff --git a/fnpdjango/utils/text/textilepl.py b/fnpdjango/utils/text/textilepl.py index 2efde25..434816b 100644 --- a/fnpdjango/utils/text/textilepl.py +++ b/fnpdjango/utils/text/textilepl.py @@ -6,17 +6,15 @@ class TextilePL(Textile): Changes opening quote to Polish lower-double. """ - glyph_defaults = [(name, repl) - for (name, repl) in Textile.glyph_defaults - if name != 'txt_quote_double_open'] - glyph_defaults.append(('txt_quote_double_open', '„')) + glyph_definitions = dict(Textile.glyph_definitions, + quote_double_open = '„' + ) def textile_pl(text): - return TextilePL().textile(text) + return TextilePL().parse(text) def textile_restricted_pl(text): - return TextilePL(restricted=True, lite=True, - noimage=True, auto_link=False).textile( - text, rel='nofollow') + return TextilePL(restricted=True, lite=True, noimage=True).parse( + text, rel='nofollow')