mirror of
https://github.com/beetbox/beets.git
synced 2025-12-25 10:05:13 +01:00
Merge pull request #2823 from waweic/patch-2
Fix album_art() in __init__.py
This commit is contained in:
commit
7fae3dadec
2 changed files with 6 additions and 2 deletions
|
|
@ -285,8 +285,8 @@ def album_query(queries):
|
|||
@app.route('/album/<int:album_id>/art')
|
||||
def album_art(album_id):
|
||||
album = g.lib.get_album(album_id)
|
||||
if album.artpath:
|
||||
return flask.send_file(album.artpath)
|
||||
if album and album.artpath:
|
||||
return flask.send_file(album.artpath.decode())
|
||||
else:
|
||||
return flask.abort(404)
|
||||
|
||||
|
|
|
|||
|
|
@ -71,6 +71,10 @@ Fixes:
|
|||
* :doc:`/plugins/web`: The time display in the web interface would incorrectly jump
|
||||
at the 30-second mark of every minute. Now, it correctly changes over at zero
|
||||
seconds. :bug:`2822`
|
||||
* :doc:`/plugins/web`: In a python 3 enviroment, the function to fetch the
|
||||
album art would not work and throw an exception. It now works as expected.
|
||||
Additionally, the server will now return a 404 response when the album id
|
||||
is unknown, instead of a 500 response and a thrown exception. :bug:`2823`
|
||||
|
||||
For developers:
|
||||
|
||||
|
|
|
|||
Loading…
Reference in a new issue