From 5137407377193b4a16f528f92ffe0a72f8566b0b Mon Sep 17 00:00:00 2001 From: Deluan Date: Mon, 23 Nov 2020 21:28:09 -0500 Subject: [PATCH] Add "keepalive" resource. It was causing issues in Firefox when using the dataProvider --- ui/src/App.js | 1 + ui/src/audioplayer/Player.js | 4 +++- 2 files changed, 4 insertions(+), 1 deletion(-) diff --git a/ui/src/App.js b/ui/src/App.js index 903674ea1..8aec2a04d 100644 --- a/ui/src/App.js +++ b/ui/src/App.js @@ -110,6 +110,7 @@ const Admin = (props) => { , , , + , , ]} diff --git a/ui/src/audioplayer/Player.js b/ui/src/audioplayer/Player.js index 1ec2421d0..3bda8adf8 100644 --- a/ui/src/audioplayer/Player.js +++ b/ui/src/audioplayer/Player.js @@ -256,7 +256,9 @@ const Player = () => { const onAudioEnded = useCallback( (currentPlayId, audioLists, info) => { dispatch(currentPlaying(info)) - dataProvider.getOne('keepalive', { id: info.trackId }) + dataProvider + .getOne('keepalive', { id: info.trackId }) + .catch((e) => console.log('Keepalive error:', e)) }, [dispatch, dataProvider] )