파라미터 없는 경우 같은 포인트 검사 못함

This commit is contained in:
hyojun.choi 2025-03-18 10:56:37 +09:00
parent 63297328ed
commit 06fa1766d6

View File

@ -305,6 +305,9 @@ export function removeDuplicatePolygons(polygons) {
}
export const isSamePoint = (a, b) => {
if (!a || !b) {
return false
}
return Math.abs(Math.round(a.x) - Math.round(b.x)) <= 2 && Math.abs(Math.round(a.y) - Math.round(b.y)) <= 2
}