Atom feeds: Properly link to art API #3129
Merged
Add this suggestion to a batch that can be applied as a single commit.
This suggestion is invalid because no changes were made to the code.
Suggestions cannot be applied while the pull request is closed.
Suggestions cannot be applied while viewing a subset of changes.
Only one suggestion per line can be applied in a batch.
Add this suggestion to a batch that can be applied as a single commit.
Applying suggestions on deleted lines is not supported.
You must change the existing code in this line in order to create a valid suggestion.
Outdated suggestions cannot be applied.
This suggestion has been applied or marked resolved.
Suggestions cannot be applied from pending reviews.
Suggestions cannot be applied on multi-line comments.
Suggestions cannot be applied while the pull request is queued to merge.
Suggestion cannot be applied right now. Please check back later.
Currently the use of _external_url_for results in a bad link to the API (lb.org/1/art/....) resulting in an error message "Please use the API at api.listenbrainz.org"
We need to manually construct a link to api.lb.org/1/art/... to fix that
Tested on test.LB with a couple different feed readers, the link is indeed fixed.
Some feed readers don't wan to render the SVG content of the feed items (for example for album grids SVGs), but having a link to the API endpoint serving the same SVG allows users to click somewhere to view the content in a browser.
Some readers have an integrated web view which can render the SVG content in a browser environment, some other feed readers also allow rendering the SVG content directly in the feed item.
I think this covers all bases.