FazBrowse GitHub Viewer | Trending |
URL:
| Home
Tools: [Download Repo ZIP]   [Original HTTPS Page]

[userscript] amazon-prime-gaming-highlighter: add openURLs helper · 0xdevalias/userscripts@83099bb · GitHub

Commit 83099bb

Browse files
committed
[userscript] amazon-prime-gaming-highlighter: add openURLs helper
1 parent 76ef9ec commit 83099bb

1 file changed

Lines changed: 10 additions & 1 deletion

File tree

‎userscripts/amazon-prime-gaming-highlighter/amazon-prime-gaming-highlighter.user.js‎

Lines changed: 10 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -295,6 +295,15 @@
295295
alert('URLs copied to clipboard!');
296296
}
297297

298+
function openURLs(urls) {
299+
if (urls.length === 0) {
300+
alert('No claim URLs found to open.');
301+
return;
302+
}
303+
304+
urls.forEach((url) => GM_openInTab(url, { active: false }));
305+
}
306+
298307
function createUtilityButtons() {
299308
const containerId = 'apgh-utility-buttons-container';
300309

@@ -382,7 +391,7 @@
382391

383392
const openButton = createButton('Open Claim URLs', () => {
384393
const urls = collectClaimURLs();
385-
urls.forEach((url) => GM_openInTab(url, { active: false }));
394+
openURLs(urls);
386395
});
387396

388397
const updateContainerVisibility = () => {

0 commit comments

Comments
 (0)

Back | FazBrowse Home | New Git URL