fix(forms): default the initial value of Control to null

This commit is contained in:
vsavkin
2015-07-16 18:34:03 -07:00
parent 4d28167bc0
commit 5b597de18c
4 changed files with 9 additions and 3 deletions
+1 -1
View File
@@ -144,7 +144,7 @@ export class AbstractControl {
export class Control extends AbstractControl {
_onChange: Function;
constructor(value: any, validator: Function = Validators.nullValidator) {
constructor(value: any = null, validator: Function = Validators.nullValidator) {
super(validator);
this._value = value;
this.updateValidity({onlySelf: true});