SimpleTextArea's onInput stops an event that may not be present
_onInput: function(e){
// Override TextBox._onInput() to enforce maxLength restriction
if(this.maxLength){
var maxLength = parseInt(this.maxLength);
var value = this.textbox.value.replace(/\r/g,'');
var overflow = value.length - maxLength;
if(overflow > 0){
dojo.stopEvent(e);
The event may or may not be passed, as subclasses, like Textarea, call _onInput to do other input validation, not in the context of an event that needs stopping. We should check to make sure e is provided before stopping it.
Change History (3)
Resolution: |
→ fixed
|
Status: |
new →
closed
|
(In [17852]) fixes #9389. check for existance of event before stopping it.