From db8f42350012f5d24ef1614d3a4183f3e76fbb95 Mon Sep 17 00:00:00 2001 From: Alvaro Vega Date: Thu, 2 Nov 2023 16:22:35 +0100 Subject: [PATCH] hceck containsKey but both in lowerCase --- .../backends/arcgis/restutils/ArcgisFeatureTable.java | 10 +++++++++- 1 file changed, 9 insertions(+), 1 deletion(-) diff --git a/cygnus-common/src/main/java/com/telefonica/iot/cygnus/backends/arcgis/restutils/ArcgisFeatureTable.java b/cygnus-common/src/main/java/com/telefonica/iot/cygnus/backends/arcgis/restutils/ArcgisFeatureTable.java index 1b67f6a8e..a2926b717 100644 --- a/cygnus-common/src/main/java/com/telefonica/iot/cygnus/backends/arcgis/restutils/ArcgisFeatureTable.java +++ b/cygnus-common/src/main/java/com/telefonica/iot/cygnus/backends/arcgis/restutils/ArcgisFeatureTable.java @@ -622,7 +622,15 @@ public int getErrorCode() { * @return */ public boolean hasAttribute(String attName) { - return arcGISFeatureTable.getTableAttributes().containsKey(attName); + // return arcGISFeatureTable.getTableAttributes().containsKey(attName); + // Check containsKey but both in lowerCase + Map map = arcGISFeatureTable.getTableAttributes(); + for (Map.Entry entry : map.entrySet()) { + if (entry.getKey().toLowerCase().equals(attName.toLowerCase())) { + return true; + } + } + return false; } /**