Permalink
Browse files

applied patch to bug #121

  • Loading branch information...
sdiehl
sdiehl committed Nov 13, 2010
1 parent 615eb81 commit 15e76be2eb8f5a7e115c023ce53f3bebb74c8b46
Showing with 7 additions and 1 deletion.
  1. +7 −1 piston/utils.py
View
@@ -224,7 +224,13 @@ def content_type(self):
"""
type_formencoded = "application/x-www-form-urlencoded"
- ctype = self.request.META.get('CONTENT_TYPE', type_formencoded)
+ # Applied patch from Bug #121 thread
+ # http://bitbucket.org/jespern/django-piston/issue/121/content-type-is-not-being-split-against
+
+ # Caused some issues with Firefox + jQuery appending UTF
+ # encoding onto the XHR request
+ ctype = self.request.META.get('CONTENT_TYPE',
+ type_formencoded).split(";")[0]
if type_formencoded in ctype:
return None

0 comments on commit 15e76be

Please sign in to comment.