Skip to content

Commit

Permalink
fix invalid JSON parse source
Browse files Browse the repository at this point in the history
  • Loading branch information
lbalmaceda committed Mar 1, 2017
1 parent 36aca42 commit 43fc54e
Showing 1 changed file with 1 addition and 1 deletion.
Original file line number Diff line number Diff line change
Expand Up @@ -131,7 +131,7 @@ protected U parseUnsuccessfulResponse(Response response) {
stringPayload = body.string();
Type mapType = new TypeToken<Map<String, Object>>() {
}.getType();
Map<String, Object> mapPayload = gson.fromJson(body.charStream(), mapType);
Map<String, Object> mapPayload = gson.fromJson(stringPayload, mapType);
return errorBuilder.from(mapPayload);
} catch (JsonSyntaxException e) {
return errorBuilder.from(stringPayload, response.code());
Expand Down

0 comments on commit 43fc54e

Please sign in to comment.