Skip to content

Commit 027b52b

Browse files
committed
fix: display points of all linear rings of a polygon
1 parent 6106f1f commit 027b52b

File tree

1 file changed

+2
-2
lines changed

1 file changed

+2
-2
lines changed

src/interaction/selectmodify.js

+2-2
Original file line numberDiff line numberDiff line change
@@ -43,8 +43,8 @@ const selectModifyStyle = new Style({
4343
// At this point multiGeometries contains only single geometry.
4444
multiGeometries.forEach((geomm) => {
4545
if (geomm.getType() === 'Polygon') {
46-
geomm.getCoordinates()[0].forEach((coordinate) => {
47-
coordinates.push(coordinate);
46+
geomm.getLinearRings().forEach((ring) => {
47+
coordinates.push(...ring.getCoordinates());
4848
});
4949
} else if (geomm.getType() === 'LineString') {
5050
coordinates.push(...geomm.getCoordinates());

0 commit comments

Comments
 (0)