From 835f1c84d865483145544e1f88f419b6fd2c0201 Mon Sep 17 00:00:00 2001 From: Santi Albo Date: Tue, 3 Sep 2013 10:22:16 +0100 Subject: [PATCH] Add typing for response objects --- restangular/restangular.d.ts | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) diff --git a/restangular/restangular.d.ts b/restangular/restangular.d.ts index 339e2444c..910eb23d7 100644 --- a/restangular/restangular.d.ts +++ b/restangular/restangular.d.ts @@ -56,11 +56,11 @@ interface RestangularProvider { addElementTransformer(route: string, transformer: Function): void; addElementTransformer(route: string, isCollection: boolean, transformer: Function): void; setOnElemRestangularized(callback: (elem: any, isCollection: boolean, what: string, restangular: Restangular) => any): void; - setResponseInterceptor(responseInterceptor: (data: any, operation: string, what: string, url: string, response: any, deferred: ng.IDeferred) => any): void; - setResponseExtractor(responseInterceptor: (data: any, operation: string, what: string, url: string, response: any, deferred: ng.IDeferred) => any): void; + setResponseInterceptor(responseInterceptor: (data: any, operation: string, what: string, url: string, response: XMLHttpRequest, deferred: ng.IDeferred) => any): void; + setResponseExtractor(responseInterceptor: (data: any, operation: string, what: string, url: string, response: XMLHttpRequest, deferred: ng.IDeferred) => any): void; setRequestInterceptor(requestInterceptor: (element: any, operation: string, what: string, url: string) => any); setFullRequestInterceptor(fullRequestInterceptor: (element: any, operation: string, what: string, url: string, headers: any, params: any) => {element: any; headers: any; params: any}); - setErrorInterceptor(errorInterceptor: (response: any) => any): void; + setErrorInterceptor(errorInterceptor: (response: XMLHttpRequest) => any): void; setRestangularFields(fields: {[fieldName: string]: string}): void; setMethodOverriders(overriders: string[]): void; setDefaultRequestParams(params: any): void;