From 576c08b5cf83ff7d69da31e7b16cc4b122dac0be Mon Sep 17 00:00:00 2001 From: xiangyu <3170102889@zju.edu.cn> Date: Sat, 28 Jan 2023 14:40:46 +0800 Subject: [PATCH] fix: default prefs loading bug --- addon/bootstrap.js | 4 +--- 1 file changed, 1 insertion(+), 3 deletions(-) diff --git a/addon/bootstrap.js b/addon/bootstrap.js index 8e9546b..4081476 100644 --- a/addon/bootstrap.js +++ b/addon/bootstrap.js @@ -80,9 +80,7 @@ async function startup({ id, version, resourceURI, rootURI }, reason) { ["locale", "__addonRef__", "zh-CN", rootURI + "chrome/locale/zh-CN/"], ]); } else { - if (reason == ADDON_INSTALL || reason == ADDON_ENABLE) { - setDefaultPrefs(rootURI); - } + setDefaultPrefs(rootURI); } // Global variables for plugin code