aboutsummaryrefslogtreecommitdiff
path: root/ext/js
diff options
context:
space:
mode:
authorKuuuube <61125188+Kuuuube@users.noreply.github.com>2024-05-10 23:27:57 -0400
committerGitHub <noreply@github.com>2024-05-11 03:27:57 +0000
commit2bcb0bccc251722b2eff8a0d07e02bca052fc2e1 (patch)
tree316de78c266dccd2a9b505be52f14bc1402b2d62 /ext/js
parentd68e93e9ca210a3653e3a464391a77b27cfd353a (diff)
Prevent updating dict entry details for anki when anki is disabled (#909)
* Prevent updating dict entry details for anki when anki is disabled * Move check to _updateDictionaryEntryDetails * Fix if
Diffstat (limited to 'ext/js')
-rw-r--r--ext/js/display/display-anki.js1
1 files changed, 1 insertions, 0 deletions
diff --git a/ext/js/display/display-anki.js b/ext/js/display/display-anki.js
index 6a6ec215..442319f7 100644
--- a/ext/js/display/display-anki.js
+++ b/ext/js/display/display-anki.js
@@ -351,6 +351,7 @@ export class DisplayAnki {
/** */
async _updateDictionaryEntryDetails() {
+ if (!this._display.getOptions()?.anki.enable) { return; }
const {dictionaryEntries} = this._display;
/** @type {?import('core').TokenObject} */
const token = {};