fix install links

This commit is contained in:
Gabe Yuan
2023-09-27 15:39:57 +08:00
parent 16fdd704aa
commit 16560fbdf0
3 changed files with 28 additions and 42 deletions

View File

@@ -85,11 +85,11 @@ export default function Popup({ setShowPopup, translator: tran }) {
const tab = await getTabInfo();
href = tab.url;
}
const rule = { ...rule, pattern: href };
const newRule = { ...rule, pattern: href };
if (isExt && tran) {
sendBgMsg(MSG_SAVE_RULE, rule);
sendBgMsg(MSG_SAVE_RULE, newRule);
} else {
saveRule(rule);
saveRule(newRule);
}
} catch (err) {
console.log("[save rule]", err);