Opened 8 years ago
Closed 8 years ago
#17235 closed defect (wontfix)
[regression] dijit.form.Select throws invalid argument error in IE8 and IE10
Reported by: | bemorris | Owned by: | Douglas Hays |
---|---|---|---|
Priority: | undecided | Milestone: | 1.8.5 |
Component: | Dijit - Form | Version: | 1.8.4 |
Keywords: | Cc: | ||
Blocked By: | Blocking: |
Description
The "invalid argument" error occurs when calling dijit.form.Select.removeOption. I debugged the code and I found the error occurs on the following line in _FormSelectWidget.getOptions:
option[a] != valueOrIdx[a]) { == and not === so that 100 matches '100' |
In IE8/10 the error happens because valueOrIndx contains "text", which is not found in the option element. I believe this line should be changed to the following:
!(a in valueOrIdx) | option[a] != valueOrIdx[a]) |
Change History (2)
comment:1 Changed 8 years ago by
Milestone: | tbd → 1.8.5 |
---|---|
Owner: | set to Douglas Hays |
Status: | new → assigned |
Summary: | dijit.form.Select throws invalid argument error in IE8 and IE10 → [regression] dijit.form.Select throws invalid argument error in IE8 and IE10 |
comment:2 Changed 8 years ago by
Resolution: | → wontfix |
---|---|
Status: | assigned → closed |
User's option array was being populated via:
options.push(domConstruct.create("option", { value: timestamp, label: this._generateOptionLabel(message, ts) }));
instead of
options.push(new Option(this._generateOptionLabel(message, ts), timestamp));
which makes IE happier.
Note: See
TracTickets for help on using
tickets.
worked in 1.7