luci-base: follow-up fix for ES6 changes

follow-up for c2fc96cc4c

Signed-off-by: Tianling Shen <cnsztl@immortalwrt.org>
This commit is contained in:
Tianling Shen 2024-12-25 13:44:57 +08:00 committed by Paul Donald
parent 527acd59a8
commit 2da1efba38

View File

@ -637,7 +637,7 @@ return baseclass.extend(/** @lends LuCI.uci.prototype */ {
}
/* only delete existing options */
if (v[conf]?.[sid].hasOwnProperty(opt)) {
if (v[conf]?.[sid]?.hasOwnProperty(opt)) {
d[conf] ??= { };
d[conf][sid] ??= { };