Skip to content

Commit 8bfadfc

Browse files
authored
Merge pull request #7 from geoanalytics-ca/master
Fix for intersectsBuilder Point type cast bug
2 parents 4d0bb63 + 289266f commit 8bfadfc

1 file changed

Lines changed: 2 additions & 2 deletions

File tree

staccato-elasticsearch/src/main/java/com/planet/staccato/es/QueryBuilderHelper.java

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -164,8 +164,8 @@ public static Optional<QueryBuilder> intersectsBuilder(Object intersects) {
164164
ShapeBuilder shapeBuilder = null;
165165
switch (type) {
166166
case "Point":
167-
double[] pointCoords = (double[]) intersectsMap.get("coordinates");
168-
shapeBuilder = new PointBuilder(pointCoords[0], pointCoords[1]);
167+
List<Double> pointCoords = (List<Double>) intersectsMap.get("coordinates");
168+
shapeBuilder = new PointBuilder(pointCoords.get(0), pointCoords.get(1));
169169
break;
170170
case "Polygon":
171171
List polygonCoords = (List) intersectsMap.get("coordinates");

0 commit comments

Comments
 (0)