fix(club): NPE on features #5

Merged
Thibaut merged 1 commits from dev into master 2025-01-20 14:58:40 +00:00

View File

@ -104,7 +104,7 @@ export function LocationEditorModal({modal, sendData}) {
}, [location]);
useEffect(() => {
if (data.features?.some((e) => e.properties.label === location)) {
if (data?.features?.some((e) => e.properties.label === location)) {
data.features.forEach((d) => {
if (d.properties.label === location) {
const {lat, lng} = convertLambert93ToLatLng(d.properties.x, d.properties.y)