react-native/Libraries/Geolocation
Rob Hogan 779f9e2b9c RCTLocationObserver: Fix reporting of timeout error
Summary:
Fixes an issue where location request timeout errors always reported "Unable to fetch location within **0s**".

Previously we had `@"Unable to fetch location within %zds.", (NSInteger)(timer.timeInterval * 1000.0)` but from the [NSTimer.timeInterval docs](https://developer.apple.com/library/mac/documentation/Cocoa/Reference/Foundation/Classes/NSTimer_Class/#//apple_ref/occ/instp/NSTimer/timeInterval) "If the receiver is a non-repeating timer, returns 0 even if a time interval was set.".

Change to use `request.options.timeout` instead, which is a `Double` defaulting to `INFINITY`. Tested on an iOS simulator.
Closes https://github.com/facebook/react-native/pull/9888

Differential Revision: D3902788

Pulled By: javache

fbshipit-source-id: aef717d6c39f3177cb7056a17adc35c1bfd94132
2016-09-21 14:28:43 -07:00
..
RCTGeolocation.xcodeproj Update React Native minimum OS version to iOS8 2016-09-01 19:43:47 -07:00
Geolocation.js - Add ability to detect if location was mocked 2016-09-20 05:59:04 -07:00
RCTLocationObserver.h Update RCTNetworking, RCTNetInfo and RCTLocationManager to use new events system 2016-05-25 04:28:36 -07:00
RCTLocationObserver.m RCTLocationObserver: Fix reporting of timeout error 2016-09-21 14:28:43 -07:00