mirror of
https://github.com/tubearchivist/tubearchivist-frontend.git
synced 2024-12-23 02:10:15 +00:00
fix error when restarting player with same video
This commit is contained in:
parent
88ebb6d648
commit
bf0b07f3d7
@ -349,7 +349,10 @@ function removePlayer() {
|
||||
if (playerElement.hasChildNodes()) {
|
||||
var youtubeId = playerElement.childNodes[0].getAttribute("data-id");
|
||||
var playedStatus = document.createDocumentFragment();
|
||||
playedStatus.appendChild(document.getElementById(youtubeId));
|
||||
var playedBox = document.getElementById(youtubeId);
|
||||
if (playedBox) {
|
||||
playedStatus.appendChild(playedBox);
|
||||
};
|
||||
playerElement.innerHTML = '';
|
||||
// append played status
|
||||
var videoInfo = document.getElementById('video-info-' + youtubeId);
|
||||
|
Loading…
Reference in New Issue
Block a user