     requestParameters: RequestParameters,
     queue: DispatchQueue = DispatchQueue.global(qos: .default),
     responseSerializer: T) -> Observable<(HTTPURLResponse, T.SerializedObject)> {
-
+    
     let requestObservable: Observable<(HTTPURLResponse, T.SerializedObject)>
     
-	if let renewTokenHandler = self.renewTokenHandler {
-		requestObservable = self.sendAutoRetryRequest({ [unowned self] () -> Observable<(HTTPURLResponse, T.SerializedObject)> in
-			
-			guard let request = self.buildRequest(requestParameters: requestParameters) else {
-				return Observable.error(NetworkStackError.requestBuildFail)
-			}
-			
-			return self.sendRequest(alamofireRequest: request, queue: queue, responseSerializer: responseSerializer)
-			}, renewTokenFunction: { () -> Observable<Void> in
-				return renewTokenHandler()
-		})
-	} else {
-		
-		guard let request = self.buildRequest(requestParameters: requestParameters) else {
-			return Observable.error(NetworkStackError.requestBuildFail)
-		}
-		
-		requestObservable = self.sendRequest(alamofireRequest: request, queue: queue, responseSerializer: responseSerializer)
-	}
-	
+    if let renewTokenHandler = self.renewTokenHandler {
+      requestObservable = self.sendAutoRetryRequest({ [unowned self] () -> Observable<(HTTPURLResponse, T.SerializedObject)> in
+        
+        guard let request = self.buildRequest(requestParameters: requestParameters) else {
+          return Observable.error(NetworkStackError.requestBuildFail)
+        }
+        
+        return self.sendRequest(alamofireRequest: request, queue: queue, responseSerializer: responseSerializer)
+        }, renewTokenFunction: { () -> Observable<Void> in
+          return renewTokenHandler()
+      })
+    } else {
+      
+      guard let request = self.buildRequest(requestParameters: requestParameters) else {
+        return Observable.error(NetworkStackError.requestBuildFail)
+      }
+      
+      requestObservable = self.sendRequest(alamofireRequest: request, queue: queue, responseSerializer: responseSerializer)
+    }
+    
     return requestObservable
-    .do(onError: { [unowned self] error in
-      self.askCredentialsIfNeeded(forError: error)
-      .subscribe()
-      .addDisposableTo(self.disposeBag)
-    })
+      .do(onError: { [unowned self] error in
+        self.askCredentialsIfNeeded(forError: error)
+          .subscribe()
+          .addDisposableTo(self.disposeBag)
+      })
   }
 }
 

  
  public func disconnect() -> Observable<Void> {
    return self.cancelAllRequest()
    .map({ [unowned self] () -> Void in
      return self.clearToken()
    })
  }
  
  fileprivate func cancelAllRequest() -> Observable<Void> {
    return Observable.just()
    .map { () -> Void in
      self.resetRequestManager()
    }
    .flatMap { () -> Observable<Void> in
      return self.resetUploadManager()
    }
  }
  

  }
  
  public func sendUploadRequestWithJSONResponse(uploadRequestParameters: UploadRequestParameters,
                                                queue: DispatchQueue = DispatchQueue.global(qos: .default)) -> Observable<(HTTPURLResponse, Any)> {
    let responseSerializer = self.defaultJSONResponseSerializer()
    return self.sendUploadRequest(uploadRequestParameters: uploadRequestParameters,
                                  queue: queue,
