Skip to content

Commit

Permalink
Add null check
Browse files Browse the repository at this point in the history
  • Loading branch information
morpheus-87 authored and clorenz committed Jan 23, 2019
1 parent 92d19cc commit 35a9366
Showing 1 changed file with 3 additions and 1 deletion.
Original file line number Diff line number Diff line change
Expand Up @@ -48,7 +48,9 @@ public ResponseEntity<String> getWebpageV1Json(

Webpage webpage = loadWebpage(pLocale, uuid);
String result = v1ObjectMapper.writeValueAsString(webpage);
result = result.replaceAll("ENTITY_PART", "RESOURCE");
if (result != null) {
result = result.replaceAll("ENTITY_PART", "RESOURCE");
}
return new ResponseEntity<>(result, HttpStatus.OK);
}

Expand Down

0 comments on commit 35a9366

Please sign in to comment.