Skip to content

Commit

Permalink
Fix JSON processing for describedBy without source (RPB-38)
Browse files Browse the repository at this point in the history
  • Loading branch information
fsteeg committed Nov 16, 2023
1 parent f385bf9 commit d4297db
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion app/models/AuthorityResource.java
Original file line number Diff line number Diff line change
Expand Up @@ -302,7 +302,7 @@ private void addRest(List<Pair<String, String>> fields) {
addArray(key, Lists.newArrayList(node.elements()), fields);
break;
case OBJECT:
if (key.equals("describedBy")) {
if (key.equals("describedBy") && node.get("source") != null) {
addValues("source", Lists.newArrayList(node.get("source").elements()).stream().map(JsonNode::asText).collect(Collectors.toList()), fields);
break;
}
Expand Down

0 comments on commit d4297db

Please sign in to comment.