diff options
author | Kuuuube <61125188+Kuuuube@users.noreply.github.com> | 2024-05-22 00:45:29 -0400 |
---|---|---|
committer | GitHub <noreply@github.com> | 2024-05-22 04:45:29 +0000 |
commit | 590b35fb19e031e37dee340d09e0802fcd3a97a1 (patch) | |
tree | b91d107b3c12c2849ce59747ca139fb14bcd4bce /ext | |
parent | e91d9ad46829fc4cab869558911344bd2fed95cd (diff) |
Add check for counts and counts.termMeta (#984)
Diffstat (limited to 'ext')
-rw-r--r-- | ext/js/pages/settings/sort-frequency-dictionary-controller.js | 2 |
1 files changed, 1 insertions, 1 deletions
diff --git a/ext/js/pages/settings/sort-frequency-dictionary-controller.js b/ext/js/pages/settings/sort-frequency-dictionary-controller.js index 774c3e35..6be24eeb 100644 --- a/ext/js/pages/settings/sort-frequency-dictionary-controller.js +++ b/ext/js/pages/settings/sort-frequency-dictionary-controller.js @@ -107,7 +107,7 @@ export class SortFrequencyDictionaryController { option.textContent = 'None'; fragment.appendChild(option); for (const {title, counts} of dictionaries) { - if (counts.termMeta.freq > 0) { + if (counts && counts.termMeta && counts.termMeta.freq > 0) { option = document.createElement('option'); option.value = title; option.textContent = title; |