chore: better openUrl for independent conversation page

This commit is contained in:
josc146
2023-04-08 20:18:38 +08:00
parent d5bc2a8ed6
commit fe5081d9ab
3 changed files with 4 additions and 2 deletions
+1 -1
View File
@@ -1,7 +1,7 @@
import Browser from 'webextension-polyfill'
export function openUrl(url) {
Browser.tabs.query({ url }).then((tabs) => {
Browser.tabs.query({ url, currentWindow: true }).then((tabs) => {
if (tabs.length > 0) {
Browser.tabs.update(tabs[0].id, { active: true })
} else {