Github user Jens-G commented on a diff in the pull request:

    https://github.com/apache/thrift/pull/1045#discussion_r71064942
  
    --- Diff: lib/haxe/src/org/apache/thrift/transport/THttpClient.hx ---
    @@ -39,12 +46,25 @@ class THttpClient extends TTransport {
         private var requestBuffer_  : BytesOutput = new BytesOutput();
         private var responseBuffer_ : BytesInput = null;
     
    +    #if !js
         private var request_        : Http = null;
    +    #else
    +    private var request_        : JsHttp = null;
    +    #end
     
     
         public function new( requestUrl : String) : Void {
    -          request_ = new Http(requestUrl);
    -        request_.addHeader( "contentType", "application/x-thrift");
    +        #if !js
    +        request_ = new Http(requestUrl);
    +        #else
    +        request_ = new JsHttp(requestUrl);
    +        request_.async = false;
    +        #end
    +        request_.addHeader("Content-Type", "application/x-thrift");
    +        request_.addHeader("Accept", "application/x-thrift");
    --- End diff --
    
    But we /are/ already adding the Content Type here. Why do we need an API 
redesign for switching a string? *confused* 


---
If your project is set up for it, you can reply to this email and have your
reply appear on GitHub as well. If your project does not have this feature
enabled and wishes so, or if the feature is enabled but not working, please
contact infrastructure at [email protected] or file a JIRA ticket
with INFRA.
---

Reply via email to