summaryrefslogtreecommitdiff
path: root/ext/js/pages/settings
diff options
context:
space:
mode:
Diffstat (limited to 'ext/js/pages/settings')
-rw-r--r--ext/js/pages/settings/dictionary-import-controller.js4
1 files changed, 3 insertions, 1 deletions
diff --git a/ext/js/pages/settings/dictionary-import-controller.js b/ext/js/pages/settings/dictionary-import-controller.js
index db9a1a50..128e18cb 100644
--- a/ext/js/pages/settings/dictionary-import-controller.js
+++ b/ext/js/pages/settings/dictionary-import-controller.js
@@ -19,6 +19,7 @@
* DictionaryController
* DictionaryDatabase
* DictionaryImporter
+ * DictionaryImporterMediaLoader
*/
class DictionaryImportController {
@@ -184,7 +185,8 @@ class DictionaryImportController {
async _importDictionary(file, importDetails, onProgress) {
const dictionaryDatabase = await this._getPreparedDictionaryDatabase();
try {
- const dictionaryImporter = new DictionaryImporter();
+ const dictionaryImporterMediaLoader = new DictionaryImporterMediaLoader();
+ const dictionaryImporter = new DictionaryImporter(dictionaryImporterMediaLoader);
const archiveContent = await this._readFile(file);
const {result, errors} = await dictionaryImporter.importDictionary(dictionaryDatabase, archiveContent, importDetails, onProgress);
yomichan.api.triggerDatabaseUpdated('dictionary', 'import');