fix time adding dirung redirection

pull/3084/head
meow 3 years ago
parent b12149bafd
commit f2f3f045e5

@ -705,8 +705,10 @@ if (location.pathname.startsWith('/embed/')) {
cb.addChild(watch_on_invidious_button); cb.addChild(watch_on_invidious_button);
} }
addEventListener('DOMContentLoaded', function () {
// Save time during redirection on another instance // Save time during redirection on another instance
const changeInstanceLink = document.querySelector('#watch-on-another-invidious-instance > a'); const changeInstanceLink = document.querySelector('#watch-on-another-invidious-instance > a');
if (changeInstanceLink) changeInstanceLink.addEventListener('click', function () { if (changeInstanceLink) changeInstanceLink.addEventListener('click', function () {
changeInstanceLink.href = addCurrentTimeToURL(changeInstanceLink.href); changeInstanceLink.href = addCurrentTimeToURL(changeInstanceLink.href);
}); });
});

Loading…
Cancel
Save