Skip to content

Commit

Permalink
Add missing error callback (#216)
Browse files Browse the repository at this point in the history
  • Loading branch information
yulapshun authored Jan 18, 2025
1 parent 85ea2b1 commit fb6b221
Show file tree
Hide file tree
Showing 2 changed files with 3 additions and 1 deletion.
1 change: 1 addition & 0 deletions src/components/layout/Header.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -65,6 +65,7 @@ const Header = () => {
({ coords: { latitude, longitude } }) => {
updateGeolocation({ lat: latitude, lng: longitude });
},
() => {},
{ enableHighAccuracy: true }
);
} catch (e) {
Expand Down
3 changes: 2 additions & 1 deletion src/context/AppContext.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -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;
Expand Down

0 comments on commit fb6b221

Please sign in to comment.