From 3e0a978dd97a55a5db072584a2bba639ed790b82 Mon Sep 17 00:00:00 2001 From: Jens Alm Date: Sat, 2 Jul 2011 19:19:45 +0200 Subject: Fixed YAMLParser = None --- djangorestframework/parsers.py | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) (limited to 'djangorestframework') diff --git a/djangorestframework/parsers.py b/djangorestframework/parsers.py index 168d391e..41f15aa3 100644 --- a/djangorestframework/parsers.py +++ b/djangorestframework/parsers.py @@ -108,7 +108,8 @@ if yaml: except ValueError, exc: raise ErrorResponse(status.HTTP_400_BAD_REQUEST, {'detail': 'YAML parse error - %s' % unicode(exc)}) - +else: + YAMLParser = None class PlainTextParser(BaseParser): """ -- cgit v1.2.3