diff options
Diffstat (limited to 'src/main/java/org/onap/aai/rest')
-rw-r--r-- | src/main/java/org/onap/aai/rest/search/GenericQueryProcessor.java | 4 |
1 files changed, 2 insertions, 2 deletions
diff --git a/src/main/java/org/onap/aai/rest/search/GenericQueryProcessor.java b/src/main/java/org/onap/aai/rest/search/GenericQueryProcessor.java index 9bcd843..85573fc 100644 --- a/src/main/java/org/onap/aai/rest/search/GenericQueryProcessor.java +++ b/src/main/java/org/onap/aai/rest/search/GenericQueryProcessor.java @@ -115,10 +115,10 @@ public abstract class GenericQueryProcessor { Map<String, Object> params = new HashMap<>(); String query = ""; if (this.isGremlin) { - query = gremlin.get(); + query = gremlin.isPresent() ? gremlin.get() : ""; }else if (this.isDsl) { - String dslUserQuery = dsl.get(); + String dslUserQuery = dsl.isPresent() ? dsl.get() : ""; if(dslQueryProcessorOptional.isPresent()){ String dslQuery = dslQueryProcessorOptional.get().parseAaiQuery(dslUserQuery); query = groovyQueryBuilder.executeTraversal(dbEngine, dslQuery, params); |