Skip to content

Commit 319fd4c

Browse files
committed
Remove timeout interval
1 parent acb6244 commit 319fd4c

File tree

1 file changed

+2
-4
lines changed

1 file changed

+2
-4
lines changed

LMGeocoder/LMGeocoder.m

Lines changed: 2 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -9,8 +9,8 @@
99
#import "LMGeocoder.h"
1010
#import "LMAddress.h"
1111

12-
#define kTimeoutInterval 60
13-
#define kLMGeocoderErrorDomain @"LMGeocoderError"
12+
static NSString * const kLMGeocoderErrorDomain = @"LMGeocoderError";
13+
1414
#define kGoogleAPIReverseGeocodingURL(lat, lng) [NSString stringWithFormat:@"https://maps.googleapis.com/maps/api/geocode/json?latlng=%f,%f&sensor=true", lat, lng];
1515
#define kGoogleAPIGeocodingURL(address) [NSString stringWithFormat:@"https://maps.googleapis.com/maps/api/geocode/json?address=%@&sensor=true", address];
1616
#define kGoogleAPIURLWithKey(url, key) [NSString stringWithFormat:@"%@&key=%@", url, key];
@@ -268,7 +268,6 @@ - (void)buildAsynchronousRequestFromURLString:(NSString *)urlString
268268
{
269269
urlString = [urlString stringByAddingPercentEncodingWithAllowedCharacters:[NSCharacterSet URLQueryAllowedCharacterSet]];
270270
NSMutableURLRequest *request = [[NSMutableURLRequest alloc] initWithURL:[NSURL URLWithString:urlString]];
271-
[request setTimeoutInterval:kTimeoutInterval];
272271

273272
NSURLSessionConfiguration *configuration = [NSURLSessionConfiguration defaultSessionConfiguration];
274273
NSURLSession *session = [NSURLSession sessionWithConfiguration:configuration];
@@ -327,7 +326,6 @@ - (NSArray *)buildSynchronousRequestFromURLString:(NSString *)urlString
327326
{
328327
urlString = [urlString stringByAddingPercentEncodingWithAllowedCharacters:[NSCharacterSet URLQueryAllowedCharacterSet]];
329328
NSMutableURLRequest *request = [[NSMutableURLRequest alloc] initWithURL:[NSURL URLWithString:urlString]];
330-
[request setTimeoutInterval:kTimeoutInterval];
331329

332330
NSURLResponse *response = nil;
333331
NSError *error = nil;

0 commit comments

Comments
 (0)