@@ -57,11 +57,11 @@ +(void)setContentType:(NSString*)ctype
5757
5858#pragma mark - GET methods
5959
60- +(id )getWithPath : (NSString *)path andParams : (NSDictionary *)params
60+ +(id )getWithPath : (NSString *)path andParams : (NSDictionary *)params error : ( NSError **) err
6161{
6262 NSString * fullURL = [NSString stringWithFormat: @" %@%@ " , sharedInstance.baseURLString, path];
6363
64- id json = [JSONHTTPClient getJSONFromURLWithString: fullURL params: params];
64+ id json = [JSONHTTPClient getJSONFromURLWithString: fullURL params: params error: err ];
6565 return json;
6666}
6767
@@ -76,11 +76,11 @@ +(void)getWithPath:(NSString*)path andParams:(NSDictionary*)params completion:(J
7676
7777#pragma mark - POST methods
7878
79- +(id )postWithPath : (NSString *)path andParams : (NSDictionary *)params
79+ +(id )postWithPath : (NSString *)path andParams : (NSDictionary *)params error : ( NSError **) err
8080{
8181 NSString * fullURL = [NSString stringWithFormat: @" %@%@ " , sharedInstance.baseURLString, path];
8282
83- id json = [JSONHTTPClient postJSONFromURLWithString: fullURL params: params];
83+ id json = [JSONHTTPClient postJSONFromURLWithString: fullURL params: params error: err ];
8484 return json;
8585}
8686
@@ -95,7 +95,7 @@ +(void)postWithPath:(NSString*)path andParams:(NSDictionary*)params completion:(
9595
9696#pragma mark - RPC 1.0 methods
9797
98- +(id )rpcWithMethodName : (NSString *)method andArguments : (NSArray *)args
98+ +(id )rpcWithMethodName : (NSString *)method andArguments : (NSArray *)args error : ( NSError **) err
9999{
100100 if (!args) args = @[];
101101
@@ -111,7 +111,8 @@ +(id)rpcWithMethodName:(NSString*)method andArguments:(NSArray*)args
111111 NSString * jsonRequestString = [[NSString alloc ] initWithData: jsonRequestData encoding: NSUTF8StringEncoding];
112112
113113 id json = [JSONHTTPClient postJSONFromURLWithString: sharedInstance.baseURLString
114- bodyString: jsonRequestString];
114+ bodyString: jsonRequestString
115+ error: err];
115116 return json;
116117}
117118
0 commit comments