From 4ced4e6aab7d67ebde7c4a356a06bc13e104192f Mon Sep 17 00:00:00 2001 From: Pouria Hadjibagheri Date: Mon, 20 Mar 2017 11:16:11 +0000 Subject: [PATCH] Backwards compatibility issue solved. --- markdownx/widgets.py | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) diff --git a/markdownx/widgets.py b/markdownx/widgets.py index c3dbb84..8260ac8 100755 --- a/markdownx/widgets.py +++ b/markdownx/widgets.py @@ -35,7 +35,7 @@ class MarkdownxWidget(forms.Textarea): :return: :rtype: """ - if not DJANGO_VERSION[:2] >= (1, 11): + if not DJANGO_VERSION[:2] < (1, 11): return super(MarkdownxWidget, self).get_context(name, value, attrs) if attrs is None: @@ -61,13 +61,13 @@ class MarkdownxWidget(forms.Textarea): :return: :rtype: """ - if not DJANGO_VERSION[:2] < (1, 11): + if not DJANGO_VERSION[:2] >= (1, 11): return super(MarkdownxWidget, self).render(name, value, attrs, renderer) attrs = self.build_attrs(attrs, name=name) attrs.update(self.add_markdownx_attrs(attrs)) - widget = super(MarkdownxWidget, self).render(name, value, attrs, renderer) + widget = super(MarkdownxWidget, self).render(name, value, attrs) template = get_template('markdownx/widget.html')