summaryrefslogtreecommitdiffstats
path: root/ui-react
diff options
context:
space:
mode:
Diffstat (limited to 'ui-react')
-rw-r--r--ui-react/src/components/dialogs/ManageDictionaries/ManageDictionaries.js12
1 files changed, 7 insertions, 5 deletions
diff --git a/ui-react/src/components/dialogs/ManageDictionaries/ManageDictionaries.js b/ui-react/src/components/dialogs/ManageDictionaries/ManageDictionaries.js
index 2af1b7ce..71477ae0 100644
--- a/ui-react/src/components/dialogs/ManageDictionaries/ManageDictionaries.js
+++ b/ui-react/src/components/dialogs/ManageDictionaries/ManageDictionaries.js
@@ -88,11 +88,13 @@ function SubDict(props) {
const {onChange} = props;
const subDicts = [];
subDicts.push('Default');
- for(var item in dictList) {
- if(dictList[item].secondLevelDictionary === 1) {
- subDicts.push(dictList[item].name);
- }
- };
+ if (dictList != "undefined" && dictList.length > 0) {
+ for(var item in dictList) {
+ if(dictList[item].secondLevelDictionary === 1) {
+ subDicts.push(dictList[item].name);
+ }
+ };
+ }
subDicts.push('');
var optionItems = subDicts.map(
(item) => <option key={item}>{item}</option>