jumblr
jumblr copied to clipboard
jumblr: Get avatar for blog. RequestBuilder.getRedirectUrl(path) throws JumblrException (response code 302. not 301)
When trying to get avatar for specific blog we always get Jumblr exception here (even though response contains correct Location header):
if(response.getCode() == 301) { return response.getHeader("Location"); } else { throw new JumblrException(response); }
as response code is 302. not 301.
Stack trace: Caused by: com.tumblr.jumblr.exceptions.JumblrException: Found at com.tumblr.jumblr.request.RequestBuilder.getRedirectUrl(RequestBuilder.java:49) at com.tumblr.jumblr.JumblrClient.blogAvatar(JumblrClient.java:271) at com.tumblr.jumblr.types.Blog.avatar(Blog.java:89) at com.tumblr.jumblr.types.Blog.avatar(Blog.java:93)
Thank you for the report. We indeed updated the response code to 302 and need to update the library to match.
cc: @ceyko