check if extension before opening all

This commit is contained in:
zombieFox
2021-09-12 15:31:00 +01:00
parent a03d403f55
commit 318993d5cc

View File

@ -182,21 +182,25 @@ export const GroupArea = function({
}), }),
open: () => { open: () => {
if (state.get.current().bookmark.newTab) { if ('tabs' in chrome) {
groupData.group.items.forEach((item, i) => { if (state.get.current().bookmark.newTab) {
chrome.tabs.create({ url: item.url });
});
} else { groupData.group.items.forEach((item, i) => {
chrome.tabs.create({ url: item.url });
});
const first = groupData.group.items.shift(); } else {
groupData.group.items.forEach((item, i) => { const first = groupData.group.items.shift();
chrome.tabs.create({ url: item.url });
});
window.location.href = first.url; groupData.group.items.forEach((item, i) => {
chrome.tabs.create({ url: item.url });
});
window.location.href = first.url;
};
}; };