From 5464ce370a916cefcd4a683cea7f2f08ac3fe91a Mon Sep 17 00:00:00 2001 From: Viktor Antropov Date: Wed, 9 Sep 2026 14:28:30 +0300 Subject: [PATCH] =?UTF-8?q?fix:=20polygons=20=D1=83=D0=B6=D0=B5=20=D1=81?= =?UTF-8?q?=D0=BE=D0=B4=D0=B5=D1=80=D0=B6=D0=B8=D1=82=20polygon.coordinate?= =?UTF-8?q?s=20=E2=80=94=20MultiPolygon.coordinates=20=3D=20polygons?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- backend/routers/water.py | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/backend/routers/water.py b/backend/routers/water.py index df3ae16..120a0fb 100644 --- a/backend/routers/water.py +++ b/backend/routers/water.py @@ -177,10 +177,10 @@ def _water_geoms(elements: list[dict]) -> list[dict]: if len(polygons) == 1: geom = polygons[0] # {'type': 'Polygon', 'coordinates': [ring]} else: - # GeoJSON MultiPolygon: собираем полигоны в один Multi. + # GeoJSON MultiPolygon: coordinates = список polygon.coordinates. geom = { 'type': 'MultiPolygon', - 'coordinates': [p['coordinates'] for p in polygons], + 'coordinates': polygons, } out.append({'layer': layer, 'name': name, 'geom': geom, 'area_m2': sum(areas),