From fb6b221b415806555bd548a00088e0bf263838bb Mon Sep 17 00:00:00 2001 From: John Date: Sat, 18 Jan 2025 23:55:00 +0100 Subject: [PATCH] Add missing error callback (#216) --- src/components/layout/Header.tsx | 1 + src/context/AppContext.tsx | 3 ++- 2 files changed, 3 insertions(+), 1 deletion(-) diff --git a/src/components/layout/Header.tsx b/src/components/layout/Header.tsx index c11efd90f935..8755b9e8f451 100644 --- a/src/components/layout/Header.tsx +++ b/src/components/layout/Header.tsx @@ -65,6 +65,7 @@ const Header = () => { ({ coords: { latitude, longitude } }) => { updateGeolocation({ lat: latitude, lng: longitude }); }, + () => {}, { enableHighAccuracy: true } ); } catch (e) { diff --git a/src/context/AppContext.tsx b/src/context/AppContext.tsx index 1c10a2ac7782..533af01f1606 100644 --- a/src/context/AppContext.tsx +++ b/src/context/AppContext.tsx @@ -298,7 +298,8 @@ export const AppContextProvider = ({ children }: AppContextProviderProps) => { const _geoWatcherId = navigator.geolocation.watchPosition( ({ coords: { latitude, longitude } }) => { updateGeolocation({ lat: latitude, lng: longitude }); - } + }, + () => {}, { enableHighAccuracy: true } ); geoWatcherId.current = _geoWatcherId;