From ac77459afb7977dac57cc8768f53664bf2e26780 Mon Sep 17 00:00:00 2001 From: Timothy Armes Date: Tue, 1 Oct 2024 09:28:37 +0200 Subject: [PATCH] Rebase changes --- src/components/MapEvents.tsx | 3 +-- 1 file changed, 1 insertion(+), 2 deletions(-) diff --git a/src/components/MapEvents.tsx b/src/components/MapEvents.tsx index 0648f4e..74c3e89 100644 --- a/src/components/MapEvents.tsx +++ b/src/components/MapEvents.tsx @@ -34,10 +34,9 @@ export const MapEvents = ({ const setMapBounds = useSetAtom(mapBoundsAtom); const [isPending, startTransition] = useTransition(); - const map = useMapEvent("moveend", () => { + useMapEvent("moveend", () => { if (!updateMapBoundsAtom) return; - useMapEvent("moveend", () => { // Set the map bounds atoms when the user pans/zooms startTransition(() => { setMapBounds(map.getBounds());