       error: r.onError
       crossDomain: true
       complete: r.onComplete
-      headers: @headers
-      data: r.params
-    for key, value of r.headers
-      request[key] = value
+      headers: headers
+      data: data
     $.ajax request
 
   performHttpRequest: (method, url, headers, parameters, success, error, complete) ->


  do: (r) ->
    data = r.params
    if @headers?.contentType? is 'application/json' and _.contains(['POST', 'PUT'], r.method)
      data = JSON.stringify data
    request =

        onError: error
        onComplete: complete

  get: (url, parameters, success, error, complete) ->
    @performHttpRequest 'GET', url, @_headerJson, parameters, success, error, complete

