Skip to content

Commit

Permalink
[playframework#323] Made WS.asJson() use play.lib.Json
Browse files Browse the repository at this point in the history
  • Loading branch information
jroper committed Apr 6, 2012
1 parent d1fc732 commit c482665
Showing 1 changed file with 1 addition and 2 deletions.
3 changes: 1 addition & 2 deletions framework/src/play/src/main/java/play/libs/WS.java
Expand Up @@ -394,9 +394,8 @@ public Document asXml() {
*/
public JsonNode asJson() {
String json = getBody();
ObjectMapper mapper = new ObjectMapper();
try {
return mapper.readValue(json, JsonNode.class);
return Json.parse(json);
} catch (Exception e) {
throw new RuntimeException(e);
}
Expand Down

0 comments on commit c482665

Please sign in to comment.