From: Andrey Kuchev
Subject: Added compatibility with Django v1.5 for HttpResponseWrapper class
 Add compatibility for django 1.5 due to HttpResponse._get_content
 not existing in Django 1.5
Origin: https://bitbucket.org/jespern/django-piston/pull-request/34/added-compatibility-with-django-v15-for
Bug-Ubuntu: https://launchpad.net/bugs/1185012

--- python-django-piston-0.2.3.orig/piston/utils.py	2013-05-28 11:45:31.666460424 -0400
+++ python-django-piston-0.2.3/piston/utils.py	2013-05-28 11:48:26.590875780 -0400
@@ -77,7 +77,15 @@
                 else:
                     self._is_string = is_string
 
-            content = property(HttpResponse._get_content, _set_content)            
+            if django.VERSION >= (1, 5):
+                # HttpResponse._get_content does not exists in Django 1.5
+
+                @HttpResponse.content.setter
+                def content(self, content):
+                    self._set_content(content)
+
+            else:
+                content = property(HttpResponse._get_content, _set_content)
 
         return HttpResponseWrapper(r, content_type='text/plain', status=c)
     
