unload player fixed

This commit is contained in:
nklhrstv 2020-03-23 12:46:58 +02:00
parent ea44bd6726
commit 3bae7de581

View file

@ -64,7 +64,7 @@ const Player = ({ urlParams }) => {
setVideoState({ [propName]: propValue });
}, []);
const onEnded = useDeepEqualMemo(() => () => {
core.dispatch({ action: 'Unload' }, 'Player');
core.dispatch({ action: 'Unload' }, 'player');
if (player.lib_item !== null) {
core.dispatch({
action: 'Ctx',
@ -217,7 +217,7 @@ const Player = ({ urlParams }) => {
duration: videoState.duration
}
}
});
}, 'player');
}
}, [videoState.time, videoState.duration]);
React.useLayoutEffect(() => {