Fix typing errors.

This commit is contained in:
Simon Seyock
2021-08-06 11:07:24 +02:00
parent d6e0eb75fa
commit f636d68cce
4 changed files with 17 additions and 5 deletions

View File

@@ -1882,8 +1882,12 @@ function readStyle(node, objectStack) {
const geometry = feature.getGeometry();
const type = geometry.getType();
if (type === GeometryType.GEOMETRY_COLLECTION) {
const collection =
/** @type {import("../geom/GeometryCollection").default} */ (
geometry
);
return new GeometryCollection(
geometry
collection
.getGeometriesArrayRecursive()
.filter(function (geometry) {
const type = geometry.getType();
@@ -1911,8 +1915,12 @@ function readStyle(node, objectStack) {
const geometry = feature.getGeometry();
const type = geometry.getType();
if (type === GeometryType.GEOMETRY_COLLECTION) {
const collection =
/** @type {import("../geom/GeometryCollection").default} */ (
geometry
);
return new GeometryCollection(
geometry
collection
.getGeometriesArrayRecursive()
.filter(function (geometry) {
const type = geometry.getType();