fixing coop enforcement - test 3
diff --git a/index.html b/index.html
@@ -444,11 +444,10 @@
if (!searchExecuted && queuedLinks.length > 0) {
queuedLinks.forEach(q => {
const link = document.createElement('a');
- link.href = q.data.url;
+ const targetUrl = q.data.url.replace('youtube.com', 'www.youtube.com');
+ link.href = targetUrl;
link.target = '_blank';
link.rel = 'noopener noreferrer';
-
- // attach to dom to make the click "trusted"
document.body.appendChild(link);
link.click();
link.remove();