Commits

Peter Sanchez committed 2f0b35a

Check for body instead of raw_post_data for Django 1.4 compat.

  • Participants
  • Parent commits 1707c99
  • Branches trunk

Comments (0)

Files changed (1)

File webutils/djtools/paypalipn.py

         return urllib.urlopen(url, data).read()
 
     def verify(self, request):
-        raw_post = request.raw_post_data + '&cmd=_notify-validate'
+        raw_post = getattr(request, 'body', request.raw_post_data)
+        raw_post += '&cmd=_notify-validate'
         return self.do_post(self.verify_url, raw_post) == 'VERIFIED'
     
     def default_response(self):