diff --git a/luci-base/htdocs/luci-static/resources/form.js b/luci-base/htdocs/luci-static/resources/form.js index ef2f18e35..58d8f7100 100644 --- a/luci-base/htdocs/luci-static/resources/form.js +++ b/luci-base/htdocs/luci-static/resources/form.js @@ -1460,7 +1460,7 @@ var CBIListValue = CBIValue.extend({ id: this.cbid(section_id), size: this.size, sort: this.keylist, - optional: this.optional, + optional: this.rmempty || this.optional, placeholder: this.placeholder, validate: L.bind(this.validate, this, section_id) }); diff --git a/luci-base/luasrc/view/cbi/lvalue.htm b/luci-base/luasrc/view/cbi/lvalue.htm index 89964563d..e07648835 100644 --- a/luci-base/luasrc/view/cbi/lvalue.htm +++ b/luci-base/luasrc/view/cbi/lvalue.htm @@ -7,7 +7,7 @@ sort = self.keylist, widget = self.widget, datatype = self.datatype, - optional = self.optional, + optional = self.optional or self.rmempty, placeholder = self.placeholder } }))%>>