From db642b859d3f3dfee1c1bb0b09b0ec0be928e349 Mon Sep 17 00:00:00 2001 From: windingwind <33902321+windingwind@users.noreply.github.com> Date: Thu, 30 Nov 2023 20:36:22 +0800 Subject: [PATCH] chore: call onStartup --- addon/bootstrap.js | 1 + src/index.ts | 2 -- 2 files changed, 1 insertion(+), 2 deletions(-) diff --git a/addon/bootstrap.js b/addon/bootstrap.js index e86118c..274ada3 100644 --- a/addon/bootstrap.js +++ b/addon/bootstrap.js @@ -37,6 +37,7 @@ async function startup({ id, version, resourceURI, rootURI }, reason) { `${rootURI}/chrome/content/scripts/__addonRef__.js`, ctx, ); + Zotero.__addonInstance__.hooks.onStartup(); } function onMainWindowLoad({ win }) { diff --git a/src/index.ts b/src/index.ts index c4790a9..acb56ed 100644 --- a/src/index.ts +++ b/src/index.ts @@ -19,8 +19,6 @@ if (!basicTool.getGlobal("Zotero")[config.addonInstance]) { }, }); Zotero[config.addonInstance] = addon; - // Trigger addon hook for initialization - addon.hooks.onStartup(); } function defineGlobal(name: Parameters[0]) {