diff --git a/app.py b/app.py index 6fabc1c..f1d42e4 100755 --- a/app.py +++ b/app.py @@ -614,13 +614,14 @@ def human_readable_size(num_bytes): num /= 1024 @app.route('/icon/.png') +@app.route('/icons/.png') # legacy path def serve_resized_icon(size): cached_image_bytes = get_cached_image(size) response = send_file( io.BytesIO(cached_image_bytes), mimetype='image/png' ) - response.headers['Cache-Control'] = 'public, max-age=86400' + response.headers['Cache-Control'] = 'public, max-age=86400, immutable' return response @app.route('/custom_logo/.png') diff --git a/static/audioplayer.js b/static/audioplayer.js index 3bebfdb..3744813 100644 --- a/static/audioplayer.js +++ b/static/audioplayer.js @@ -197,7 +197,7 @@ class SimpleAudioPlayer { navigator.mediaSession.metadata = new MediaMetadata({ title : file.replace(/\.[^/.]+$/, ''), artist: parts.pop(), - artwork: [{ src:'/icons/logo-192x192.png', sizes:'192x192', type:'image/png' }] + artwork: [{ src:'/icon/logo-192x192.png', sizes:'192x192', type:'image/png' }] }); } } catch (err) { @@ -266,4 +266,3 @@ class SimpleAudioPlayer { // Initialize instance const player = new SimpleAudioPlayer(); -