diff --git a/packages/tupaia-web/src/features/Map/utils/processMeasureData.ts b/packages/tupaia-web/src/features/Map/utils/processMeasureData.ts index 0a11d311b7..266194b5c0 100644 --- a/packages/tupaia-web/src/features/Map/utils/processMeasureData.ts +++ b/packages/tupaia-web/src/features/Map/utils/processMeasureData.ts @@ -56,7 +56,7 @@ export const processMeasureData = ({ // for radius overlay sort desc radius to place smaller circles over larger circles if (serieses.some(l => l.type === MEASURE_TYPE_RADIUS)) { - entityMeasureData.sort((a, b) => Number(b.radius) - Number(a.radius)); + entityMeasureData?.sort((a, b) => Number(b.radius) - Number(a.radius)); } return entityMeasureData;