Обновить script.js
This commit is contained in:
parent
a193f4d6b0
commit
05fcb4c61b
1 changed files with 1 additions and 1 deletions
|
|
@ -18,7 +18,7 @@
|
||||||
}
|
}
|
||||||
await delay(150);
|
await delay(150);
|
||||||
}
|
}
|
||||||
// fallback: глобальная кнопка по тексту
|
|
||||||
const global = Array.from(document.querySelectorAll('button, tp-yt-paper-button')).find(el=>(el.textContent||'').toLowerCase().includes('отказаться от подписки') || (el.textContent||'').toLowerCase().includes('отписаться'));
|
const global = Array.from(document.querySelectorAll('button, tp-yt-paper-button')).find(el=>(el.textContent||'').toLowerCase().includes('отказаться от подписки') || (el.textContent||'').toLowerCase().includes('отписаться'));
|
||||||
if(global){ try{ global.click(); return true; }catch(e){console.warn(e);} }
|
if(global){ try{ global.click(); return true; }catch(e){console.warn(e);} }
|
||||||
return false;
|
return false;
|
||||||
|
|
|
||||||
Loading…
Add table
Add a link
Reference in a new issue