Skip to content

Commit ea8cf78

Browse files
committed
Changes return format
1 parent 7bf44b1 commit ea8cf78

File tree

1 file changed

+4
-1
lines changed

1 file changed

+4
-1
lines changed

src/main/java/io/appsfly/core/AppInstance.java

Lines changed: 4 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -109,9 +109,12 @@ public JSONObject execSync(final String intent, final JSONObject intentData, fin
109109
String responseChecksum = response.headers().get("X-Checksum");
110110
if(responseChecksum!=null){
111111
byte[] bytes = response.body().bytes();
112+
System.out.println(bytes.length);
113+
ResponseBody data = response.body();
114+
System.out.println(data.toString());
112115
boolean verified = CtyptoUtil.getInstance().verifychecksum(bytes, responseChecksum, config.secretKey);
113116
if (verified){
114-
return new JSONObject(bytes);
117+
return new JSONObject(data.string());
115118
}
116119
else{
117120
throw new AppsflyException("Checksum Validation Failed");

0 commit comments

Comments
 (0)