Skip to content

Commit

Permalink
addressed issue #44. format corrected replying multiple Link headers
Browse files Browse the repository at this point in the history
  • Loading branch information
benni committed Dec 6, 2019
1 parent a813f36 commit 124cd01
Show file tree
Hide file tree
Showing 2 changed files with 5 additions and 2 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -788,7 +788,10 @@ public ResponseEntity<Object> generateReply(String replyBody, HashMap<String, Li
BodyBuilder builder = ResponseEntity.status(status);
if (additionalHeaders != null) {
for (Entry<String, List<String>> entry : additionalHeaders.entrySet()) {
builder.header(entry.getKey(), entry.getValue().toArray(new String[0]));
for(String value: entry.getValue()) {
builder.header(entry.getKey(), value);
}

}
}
return builder.body(replyBody);
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -263,7 +263,7 @@ private String generateFollowUpLinkHeader(HttpServletRequest request, int offset
}
builder.append("offset=" + offset + "&");
builder.append("limit=" + limit + "&");
builder.append("qtoken=" + token + ">rel=\"" + rel + "\"");
builder.append("qtoken=" + token + ">;rel=\"" + rel + "\"");
return builder.toString();
}

Expand Down

0 comments on commit 124cd01

Please sign in to comment.