From 8a3f4b4e421edf02f0f55586e4028c240e954c13 Mon Sep 17 00:00:00 2001 From: gdh1995 Date: Tue, 2 Jul 2024 01:43:06 +0800 Subject: [PATCH] fix the last commit --- background/parse_urls.ts | 2 +- background/settings.ts | 14 ++++++-------- 2 files changed, 7 insertions(+), 9 deletions(-) diff --git a/background/parse_urls.ts b/background/parse_urls.ts index d00e45075..4be077b72 100644 --- a/background/parse_urls.ts +++ b/background/parse_urls.ts @@ -380,7 +380,7 @@ export const parseSearchEngines_ = (str: string, map: Map val = val.replace(> /\\s/g, " " ).trim().replace(> /([^\\]|^)%(s)/gi, "$1$$$2" ).replace(> /\\%/g, "%"); - obj = { name_: "", url_: val, blank_: blank, complex_: map.size > 0 } + obj = { name_: "", url_: val, blank_: blank, complex_: map.size > 1 } if (ids.includes("~") && obj.complex_) { convertToUrl_(val, null, Urls.WorkType.KeepAll) if (lastUrlType_ > Urls.Type.MaxOfInputIsPlainUrl) { diff --git a/background/settings.ts b/background/settings.ts index 575bf52b2..f09536bb8 100644 --- a/background/settings.ts +++ b/background/settings.ts @@ -18,8 +18,7 @@ type SettingsUpdateMsg = { } type PersistentKeys = keyof SettingsNS.PersistentSettings -const kBrowserSearch2 = "vimium://b-search-at/new-tab/$s" -const kBrowserSearch2Line = "_browser: " + kBrowserSearch2 + " Browser default search\n" +const kBrowserSearch2Line = "_browser: vimium://b-search-at/new-tab/$s re= Browser default search" let newSettingsToBroadcast_: Extract | null = null let toSaveCache: SafeDict | null = null export let needToUpgradeSettings_ = 0 @@ -280,7 +279,7 @@ Object.assign