Permalink
Browse files
fix(ngModelController): always use the most recent viewValue for vali…
…dation This fixes issues where a parser calls $setViewValue. This is a common strategy for manipulating the $viewValue while the user is entering data into an input field. When the $viewValue was changed inside the parser, the new viewValue would be committed, parsed and used for validation. The original parser however would run after that and pass the original (outdated) viewValue on to the validators, which could cause false positives, e.g. for minlength. Fixes #10126 Fixes #10299
- Loading branch information
Showing
with
55 additions
and 1 deletion.
- +5 −1 src/ng/directive/input.js
- +50 −0 test/ng/directive/inputSpec.js