 
     return promise
   }
-  
+
   // MARK: - Authentication
 
   public func authenticate(username username: String, password: String) {
     guard let header = Header.authentication(username: username, password: password) else {
       return
     }
-    
+
     customHeaders["Authorization"] = header
   }
-  
+
   func authenticate(authorizationHeader authorizationHeader: String) {
     customHeaders["Authorization"] = authorizationHeader
   }
-  
+
   func authenticate(bearerToken bearerToken: String) {
     customHeaders["Authorization"] = "Bearer \(bearerToken)"
   }
-  
+
   // MARK: - Helpers
-  
+
   func saveEtag(key: String, response: NSHTTPURLResponse) {
     guard let etag = response.allHeaderFields["ETag"] as? String else {
       return

  func execute(method: Method, request: Requestable) -> Promise<NetworkResult> {
    let promise = Promise<NetworkResult>()
    let URLRequest: NSMutableURLRequest
    
    do {
      URLRequest = try request.toURLRequest(method,
        baseURLString: baseURLString, additionalHeaders: requestHeaders)

  enum SessionTaskKind {
    case Data, Upload, Download
  }

  public var additionalHeaders = [String: String]()

  var baseURLString: URLStringConvertible?
