diff --git a/geoportal-common/src/main/java/org/gcube/application/geoportal/common/model/JSONPathWrapper.java b/geoportal-common/src/main/java/org/gcube/application/geoportal/common/model/JSONPathWrapper.java index b40869e..88c2b75 100644 --- a/geoportal-common/src/main/java/org/gcube/application/geoportal/common/model/JSONPathWrapper.java +++ b/geoportal-common/src/main/java/org/gcube/application/geoportal/common/model/JSONPathWrapper.java @@ -60,7 +60,7 @@ public class JSONPathWrapper { } public List getByPath(String path){ - return valueCTX.read(path); + return getByPath(path,Object.class); } public List getMatchingPaths(String path){return pathsCTX.read(path); } diff --git a/geoportal-common/src/test/java/org/gcube/application/geoportal/common/model/JSONPathTests.java b/geoportal-common/src/test/java/org/gcube/application/geoportal/common/model/JSONPathTests.java index ff9a6a7..ddb2443 100644 --- a/geoportal-common/src/test/java/org/gcube/application/geoportal/common/model/JSONPathTests.java +++ b/geoportal-common/src/test/java/org/gcube/application/geoportal/common/model/JSONPathTests.java @@ -42,6 +42,8 @@ public class JSONPathTests { @Test public void readElements() throws IOException { + JSONPathWrapper documentNavigator=getNavigator("profiledConcessioneExample.json"); + }