Fixed a bug where user couldn't add custom headers.
authorBartek Sarul <bodziec@gmail.com>
Sun, 16 Dec 2012 14:59:28 +0000 (15:59 +0100)
committerBartek Sarul <bodziec@gmail.com>
Sun, 16 Dec 2012 14:59:28 +0000 (15:59 +0100)
requests/models.py

index 342d3e49e707b29f1771a29386246bf637bcf186..a020041b8c745e44ccc59ea62e5e7c28bc8c998a 100644 (file)
@@ -295,7 +295,7 @@ class PreparedRequest(RequestMixin):
         """Prepares the given HTTP headers."""
 
         if headers:
-            self.headers = CaseInsensitiveDict(self.headers)
+            self.headers = CaseInsensitiveDict(headers)
         else:
             self.headers = CaseInsensitiveDict()