diff options
Diffstat (limited to 'ext/js/background')
-rw-r--r-- | ext/js/background/backend.js | 12 |
1 files changed, 0 insertions, 12 deletions
diff --git a/ext/js/background/backend.js b/ext/js/background/backend.js index a4cf6949..765d17d9 100644 --- a/ext/js/background/backend.js +++ b/ext/js/background/backend.js @@ -189,7 +189,6 @@ export class Backend { ['textHasJapaneseCharacters', this._onApiTextHasJapaneseCharacters.bind(this)], ['getTermFrequencies', this._onApiGetTermFrequencies.bind(this)], ['findAnkiNotes', this._onApiFindAnkiNotes.bind(this)], - ['loadExtensionScripts', this._onApiLoadExtensionScripts.bind(this)], ['openCrossFramePort', this._onApiOpenCrossFramePort.bind(this)] ]); /* eslint-enable no-multi-spaces */ @@ -846,17 +845,6 @@ export class Backend { return await this._anki.findNotes(query); } - /** @type {import('api').ApiHandler<'loadExtensionScripts'>} */ - async _onApiLoadExtensionScripts({files}, sender) { - if (!sender || !sender.tab) { throw new Error('Invalid sender'); } - const tabId = sender.tab.id; - if (typeof tabId !== 'number') { throw new Error('Sender has invalid tab ID'); } - const {frameId} = sender; - for (const file of files) { - await this._scriptManager.injectScript(file, tabId, frameId, false); - } - } - /** @type {import('api').ApiHandler<'openCrossFramePort'>} */ _onApiOpenCrossFramePort({targetTabId, targetFrameId}, sender) { const sourceTabId = (sender && sender.tab ? sender.tab.id : null); |