Skip to content

Commit

Permalink
Merge pull request #9270 from camptocamp/backport/9269-to-master
Browse files Browse the repository at this point in the history
[Backport master] Fix for index == 0
  • Loading branch information
sbrunner authored Dec 13, 2023
2 parents ca3ed3a + f1f6311 commit 191cef2
Showing 1 changed file with 2 additions and 2 deletions.
4 changes: 2 additions & 2 deletions src/format/ArcGISGeoJSON.js
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
// The MIT License (MIT)
//
// Copyright (c) 2019-2022 Camptocamp SA
// Copyright (c) 2019-2023 Camptocamp SA
//
// Permission is hereby granted, free of charge, to any person obtaining a copy of
// this software and associated documentation files (the "Software"), to deal in
Expand Down Expand Up @@ -97,7 +97,7 @@ class ArcGISGeoJSON extends olFormatGeoJSON {
// @ts-ignore: Arcgis specific
const layerName = feature[layerIdentifier];
// Exclude feature if its layer name is not set among the layers
if (this.layers_ && !this.layers_.indexOf(layerName)) {
if (this.layers_ && !this.layers_.includes(layerName)) {
continue;
}
features.push(this.readFeatureFromObject(geoJSONFeatures[i], opt_options));
Expand Down

0 comments on commit 191cef2

Please sign in to comment.