mirror of
https://github.com/th-ch/youtube-music.git
synced 2026-01-15 04:11:47 +00:00
Fix apiLoaded event listener in video-toggle plugin
This commit is contained in:
@ -14,7 +14,7 @@ const switchButtonDiv = ElementFromFile(
|
|||||||
module.exports = (_options) => {
|
module.exports = (_options) => {
|
||||||
if (_options.forceHide) return;
|
if (_options.forceHide) return;
|
||||||
options = _options;
|
options = _options;
|
||||||
document.addEventListener('apiLoaded', setup);
|
document.addEventListener('apiLoaded', setup, { once: true, passive: true });
|
||||||
}
|
}
|
||||||
|
|
||||||
function setup() {
|
function setup() {
|
||||||
|
|||||||
Reference in New Issue
Block a user