summaryrefslogtreecommitdiffhomepage
diff options
context:
space:
mode:
-rw-r--r--modules/luci-base/htdocs/luci-static/resources/ui.js5
1 files changed, 1 insertions, 4 deletions
diff --git a/modules/luci-base/htdocs/luci-static/resources/ui.js b/modules/luci-base/htdocs/luci-static/resources/ui.js
index 9433659f7d..51b6c0902d 100644
--- a/modules/luci-base/htdocs/luci-static/resources/ui.js
+++ b/modules/luci-base/htdocs/luci-static/resources/ui.js
@@ -820,7 +820,7 @@ var UISelect = UIElement.extend(/** @lends LuCI.ui.Select.prototype */ {
'type': this.options.multiple ? 'checkbox' : 'radio',
'class': this.options.multiple ? 'cbi-input-checkbox' : 'cbi-input-radio',
'value': keys[i],
- 'checked': ((!i && !this.values.length) || this.values.indexOf(keys[i]) > -1) ? '' : null,
+ 'checked': (this.values.indexOf(keys[i]) > -1) ? '' : null,
'disabled': this.options.disabled ? '' : null
}),
E('label', { 'for': this.options.id ? 'widget.%s.%d'.format(this.options.id, i) : null }),
@@ -832,9 +832,6 @@ var UISelect = UIElement.extend(/** @lends LuCI.ui.Select.prototype */ {
]));
frameEl.appendChild(brEl.cloneNode());
-
- if (!frameEl.querySelector('> span > input[checked]')
- frameEl.querySelector('> span > input').checked = true;
}
}