mirror of
https://github.com/Shik3i/KoalaSync.git
synced 2026-07-26 12:08:15 +00:00
Merge pull request #4 from Shik3i/alert-autofix-3
Potential fix for code scanning alert no. 3: Incomplete URL substring sanitization
This commit is contained in:
@@ -262,8 +262,8 @@
|
||||
|
||||
try {
|
||||
const host = window.location.hostname.toLowerCase();
|
||||
const isYouTube = host.includes('youtube.com');
|
||||
const isTwitch = host.includes('twitch.tv');
|
||||
const isYouTube = host === 'youtube.com' || host.endsWith('.youtube.com');
|
||||
const isTwitch = host === 'twitch.tv' || host.endsWith('.twitch.tv');
|
||||
|
||||
if (isYouTube) {
|
||||
const ytButton = document.querySelector('.ytp-play-button');
|
||||
|
||||
Reference in New Issue
Block a user