From 8af6aefd54330b83a2dfcd0365df775aa50a8749 Mon Sep 17 00:00:00 2001 From: Adrian Paul Matos Date: Tue, 9 Aug 2016 04:31:37 -0700 Subject: [PATCH] Fix alert's error message Summary: `error` is not an object so `error.message` will return 'undefined' Closes https://github.com/facebook/react-native/pull/9271 Differential Revision: D3689980 Pulled By: javache fbshipit-source-id: 07de946f04cdff0e8013faa2c5512c51c82147b9 --- Examples/UIExplorer/js/GeolocationExample.js | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/Examples/UIExplorer/js/GeolocationExample.js b/Examples/UIExplorer/js/GeolocationExample.js index c9f3fbcbc..96a6472b0 100644 --- a/Examples/UIExplorer/js/GeolocationExample.js +++ b/Examples/UIExplorer/js/GeolocationExample.js @@ -59,7 +59,7 @@ class GeolocationExample extends React.Component { var initialPosition = JSON.stringify(position); this.setState({initialPosition}); }, - (error) => alert(error.message), + (error) => alert(error), {enableHighAccuracy: true, timeout: 20000, maximumAge: 1000} ); this.watchID = navigator.geolocation.watchPosition((position) => {