javaduke commented on code in PR #8023:
URL: https://github.com/apache/camel/pull/8023#discussion_r929161895


##########
components/camel-datasonnet/src/main/java/org/apache/camel/language/datasonnet/DatasonnetExpression.java:
##########
@@ -114,7 +114,11 @@ private Document<?> doEvaluate(Exchange exchange) {
         }
 
         Document<?> body;
-        if (exchange.getMessage().getBody() instanceof Document) {
+
+        if (exchange.getMessage().getBody() == null || 
"".equals(MessageHelper.extractBodyAsString(exchange.getMessage()))) {

Review Comment:
   OK, I changed the logic slightly, but I still need to ensure that if it's 
null or an empty string, I force APPLICATION_JAVA with empty string to DS.



-- 
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

To unsubscribe, e-mail: commits-unsubscr...@camel.apache.org

For queries about this service, please contact Infrastructure at:
us...@infra.apache.org

Reply via email to