From 09092ac3c275b9ef8dadbec095ab5ede25c8b9a7 Mon Sep 17 00:00:00 2001 From: Dzmitry Shylovich Date: Wed, 9 Nov 2016 02:44:36 +0300 Subject: [PATCH] fix(forms): getRawValue returns any instead of Object (#12599) --- modules/@angular/forms/src/model.ts | 2 +- tools/public_api_guard/forms/index.d.ts | 2 +- 2 files changed, 2 insertions(+), 2 deletions(-) diff --git a/modules/@angular/forms/src/model.ts b/modules/@angular/forms/src/model.ts index 1dd3cfa348..929eef663d 100644 --- a/modules/@angular/forms/src/model.ts +++ b/modules/@angular/forms/src/model.ts @@ -1016,7 +1016,7 @@ export class FormGroup extends AbstractControl { * If you'd like to include all values regardless of disabled status, use this method. * Otherwise, the `value` property is the best way to get the value of the group. */ - getRawValue(): Object { + getRawValue(): any { return this._reduceChildren( {}, (acc: {[k: string]: AbstractControl}, control: AbstractControl, name: string) => { acc[name] = control.value; diff --git a/tools/public_api_guard/forms/index.d.ts b/tools/public_api_guard/forms/index.d.ts index 7604a0cb6f..28a6536ffa 100644 --- a/tools/public_api_guard/forms/index.d.ts +++ b/tools/public_api_guard/forms/index.d.ts @@ -269,7 +269,7 @@ export declare class FormGroup extends AbstractControl { }, validator?: ValidatorFn, asyncValidator?: AsyncValidatorFn); addControl(name: string, control: AbstractControl): void; contains(controlName: string): boolean; - getRawValue(): Object; + getRawValue(): any; patchValue(value: { [key: string]: any; }, {onlySelf, emitEvent}?: {