     private func dataTask(urlRequest: NSURLRequest, success: () -> Void , failure: (error: APIError) -> () ) -> NSURLSessionTask? {
         let task = session.dataTaskWithRequest(urlRequest, completionHandler: { (data,response, error) in
             dispatch_async(dispatch_get_main_queue(), {
+                let htttpURL = response as NSHTTPURLResponse
+                println(htttpURL)
                 if self.isUnauthorized(response as NSHTTPURLResponse?) {
                     self.removeAccessToken()
                     failure(error: APIError.UnauthorizedOAuthTokenError())

        var urlRequest = NSMutableURLRequest(URL: url!, cachePolicy: .ReturnCacheDataElseLoad, timeoutInterval: 50)
        urlRequest.HTTPMethod = method.rawValue
        urlRequest.allHTTPHeaderFields![Constants.HTTPHeaderKeys.accept] = acceptHeader
        
        disposable = RACSignalSubscriptionNext(selector: Selector("URLSession:downloadTask:didFinishDownloadingToURL:"), fromProtocol: NSURLSessionDownloadDelegate.self) { (racTuple) -> Void in
            if let location = racTuple.objectAtIndex(2) as? NSURL {
                let contents = NSData(contentsOfURL: location)

                }
            })
        }
        RACSignalSubscriptionNext(selector: Selector("URLSession:task:didCompleteWithError:"), fromProtocol: NSURLSessionTaskDelegate.self) { (racTuple) -> Void in
            println(racTuple)
            let urlSession = racTuple.first as NSURLSession
            let downloadTask = racTuple.second as NSURLSessionTask
            println(urlSession)
            println(downloadTask)
            //            let location = racTuple.third as NSError
            //            success(url: location)
            //            self.disposable?.dispose()
        }

        let task = session.downloadTaskWithRequest(urlRequest, completionHandler: nil)
        lastPerformedTask = task
        return task
