Fix (or workaround) for bug 586032 in the BzAPI.
authorShawn Wilsher <sdwilsh@shawnwilsher.com>
Tue, 10 Aug 2010 14:44:13 -0700
changeset 58 53d8f9a29d28
parent 57 e5b7a3317164
child 59 f642a696d003
push id28
push usersdwilsh@shawnwilsher.com
push date2010-08-10 21:47 +0000
bugs586032
Fix (or workaround) for bug 586032 in the BzAPI.
resource/BugzillaAPI.jsm
--- a/resource/BugzillaAPI.jsm
+++ b/resource/BugzillaAPI.jsm
@@ -216,17 +216,17 @@ function performRequest(aServer,
     gOfflineQueue.push(arguments);
     return;
   }
 
   let channel = ioService.newChannel(aURI, null, null);
   channel.QueryInterface(Ci.nsIHttpChannel);
   channel.QueryInterface(Ci.nsIUploadChannel);
   channel.QueryInterface(Ci.nsIHttpChannel);
-  channel.setRequestHeader("Accept", "application/json", true);
+  channel.setRequestHeader("Accept", "application/json", false);
   channel.loadFlags |= Ci.nsIRequest.LOAD_BYPASS_CACHE;
   if (aData) {
     let converter = Cc["@mozilla.org/intl/scriptableunicodeconverter"].
                     createInstance(Ci.nsIScriptableUnicodeConverter);
     converter.charset = "UTF-8";
     let is = converter.convertToInputStream(aData);
     channel.setUploadStream(is, "application/json", -1);
     channel.requestMethod = "POST";