Fix error when setting typedInput to boolean true/false

This commit is contained in:
Nick O'Leary
2019-10-03 15:04:27 +01:00
parent b763e0b0cb
commit c09004dbc8

View File

@@ -632,7 +632,7 @@
for (var i=0;i<opt.options.length;i++) {
var op = opt.options[i];
if (typeof op === "string") {
if (op === value) {
if (op === value || op === ""+value) {
selectedOption.push(that.activeOptions[op]);
break;
}
@@ -644,7 +644,7 @@
})
this.input.val(value);
if (!opt.multiple) {
if (!selectedOption.length === 0) {
if (selectedOption.length === 0) {
selectedOption = [{value:""}];
}
this._updateOptionSelectLabel(selectedOption[0])