     
     // MARK: - Cache Response
     
-    private func cacheSearchResponse<T: NSManagedObject>(response: [[String: UInt]]) throws -> [T] {
+    private func cacheSearchResponse<T: NSManagedObject>(response: DataTaskResponse) throws -> [T] {
+        
+        let jsonResponse = try self.validateSearchResponse(response)
         
         // get results as cached resources...
         

        
        try self.privateQueueManagedObjectContext.performErrorBlock({ () -> Void in
            
            for resourceIDByResourcePath in response {
                
                let resourcePath = resourceIDByResourcePath.keys.first!
                

        
        let request = NSMutableURLRequest(URL: resourceURL)
        
        request.HTTPMethod = RequestType.Edit.HTTPMethod.rawValue
        
        request.HTTPBody = NSData(JSON: changes, prettyPrintJSON: self.prettyPrintJSON)
        
        return request
    }
