From 4a6dfcb759cb6da970dac55a0b9a116114ce71e7 Mon Sep 17 00:00:00 2001 From: RaNaN Date: Mon, 23 Aug 2010 15:31:41 +0200 Subject: fixes for django 1.1 --- module/web/pyload/templatetags/token.py | 8 ++++++-- 1 file changed, 6 insertions(+), 2 deletions(-) (limited to 'module/web/pyload') diff --git a/module/web/pyload/templatetags/token.py b/module/web/pyload/templatetags/token.py index fc190db73..e6117b839 100644 --- a/module/web/pyload/templatetags/token.py +++ b/module/web/pyload/templatetags/token.py @@ -5,9 +5,13 @@ register = template.Library() if VERSION[:3] < (1,1,2): + class TokenNode(template.Node): + def render(self, content): + return "" + @register.tag() - def csrf_token(): + def csrf_token(parser, token): """ Return nothing, since csrf is deactivated in django 1.1 """ - return "" + return TokenNode() -- cgit v1.2.3