diff --git a/modules/http-client/src/main/java/org/jpos/http/client/HttpQuery.java b/modules/http-client/src/main/java/org/jpos/http/client/HttpQuery.java index dc73d8484c..cd7e42dc71 100644 --- a/modules/http-client/src/main/java/org/jpos/http/client/HttpQuery.java +++ b/modules/http-client/src/main/java/org/jpos/http/client/HttpQuery.java @@ -198,10 +198,11 @@ private HttpRequestBase getHttpRequest(Context ctx) { } private ContentType getContentType (Context ctx) { - return ContentType.create(ctx.get(contentTypeName, contentType), Consts.UTF_8); + return cfg.getBoolean("no-charset") ? + ContentType.create(ctx.get(contentTypeName, contentType)) : + ContentType.create(ctx.get(contentTypeName, contentType), Consts.UTF_8); } - @SuppressWarnings("unchecked") private void addHeaders(Context ctx, HttpUriRequest req) { // first add the ones from the cfg