diff --git a/ext/bg/js/options-form.js b/ext/bg/js/options-form.js
index 849916bd..0f2fcc6a 100644
--- a/ext/bg/js/options-form.js
+++ b/ext/bg/js/options-form.js
@@ -55,18 +55,19 @@ function populateAnkiDeckAndModel(opts) {
names.forEach((name) => ankiDeck.append($('', {value: name, text: name})));
}
- const ankiModel = $('.anki-model');
- ankiModel.find('option').remove();
- yomi.api_getModelNames({callback: (names) => {
- if (names !== null) {
- names.forEach((name) => ankiModel.append($('', {value: name, text: name})));
- }
+ $('#anki-vocab-deck').val(opts.ankiVocabDeck);
+ $('#anki-kanji-deck').val(opts.ankiKanjiDeck);
+ }});
- $('#anki-vocab-deck').val(opts.ankiVocabDeck);
- populateAnkiFields($('#anki-vocab-model').val(opts.ankiVocabModel), opts);
- $('#anki-kanji-deck').val(opts.ankiKanjiDeck);
- populateAnkiFields($('#anki-kanji-model').val(opts.ankiKanjiModel), opts);
- }});
+ const ankiModel = $('.anki-model');
+ ankiModel.find('option').remove();
+ yomi.api_getModelNames({callback: (names) => {
+ if (names !== null) {
+ names.forEach((name) => ankiModel.append($('', {value: name, text: name})));
+ }
+
+ populateAnkiFields($('#anki-vocab-model').val(opts.ankiVocabModel), opts);
+ populateAnkiFields($('#anki-kanji-model').val(opts.ankiKanjiModel), opts);
}});
}