Skip to content

Commit

Permalink
ensure no leading or trailing whitespace (#45)
Browse files Browse the repository at this point in the history
  • Loading branch information
pnzrr authored Oct 18, 2024
1 parent 927c038 commit 9f4d462
Showing 1 changed file with 2 additions and 1 deletion.
Original file line number Diff line number Diff line change
Expand Up @@ -70,7 +70,8 @@ private Response resourceRedirect(UriInfo uriInfo, String key, String defaultPat
"%s/%s/%s",
theme.getType().toString().toLowerCase(), theme.getName(), defaultPath));
} else {
redir = new URI(imgUrl);
// ensure no leading or following spaces
redir = new URI(imgUrl.trim());
}
log.debugf("redirecting to %s", redir);
return Response.seeOther(redir).build();
Expand Down

0 comments on commit 9f4d462

Please sign in to comment.