Commit d33b1d12 authored by Romain Loth's avatar Romain Loth

fix empty menu bug

parent 9951cce0
...@@ -22,8 +22,13 @@ function selectSavedMenus(uinfo) { ...@@ -22,8 +22,13 @@ function selectSavedMenus(uinfo) {
var colName = cmxClt.COLS[i][0] var colName = cmxClt.COLS[i][0]
var chosenV = uinfo[colName] var chosenV = uinfo[colName]
var selectElt = document.getElementById(colName) var selectElt = document.getElementById(colName)
if (selectElt) {
selectElt.selectedIndex = selectElt.querySelector(`option[value="${chosenV}"]`).index selectElt.selectedIndex = selectElt.querySelector(`option[value="${chosenV}"]`).index
} }
else {
console.warn("selectSavedMenus: couldn't find element: "+colName)
}
}
} }
} }
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment