From 359244c34d6ed582d2e6abd4f46f82922cf8d820 Mon Sep 17 00:00:00 2001 From: juwon5272 <98096178+juwon5272@users.noreply.github.com> Date: Mon, 2 Dec 2024 18:37:03 +0900 Subject: [PATCH] =?UTF-8?q?[FE][Feat]=20:=20null=EB=A1=9C=20=EC=9D=B8?= =?UTF-8?q?=ED=95=9C=20=EC=98=A4=EB=A5=98=20=ED=95=B4=EA=B2=B0?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- frontend/src/hooks/useRedraw.ts | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/frontend/src/hooks/useRedraw.ts b/frontend/src/hooks/useRedraw.ts index b48ac668..1944b0d2 100644 --- a/frontend/src/hooks/useRedraw.ts +++ b/frontend/src/hooks/useRedraw.ts @@ -197,7 +197,7 @@ export const useRedrawCanvas = ({ // } // }; const drawPath = (ctx: CanvasRenderingContext2D, points: ILatLng[]) => { - if (points.length === 0 || !footprintRef.current) return; + if (points.length === 0 || !footprintRef.current || !map) return; const footprintImage = footprintRef.current; const markerSize = Math.min(map.getZoom() * 2, 20);