diff --git a/modules/@angular/common/src/forms-deprecated/directives/ng_control_name.ts b/modules/@angular/common/src/forms-deprecated/directives/ng_control_name.ts index 89aea96e99..23e281e061 100644 --- a/modules/@angular/common/src/forms-deprecated/directives/ng_control_name.ts +++ b/modules/@angular/common/src/forms-deprecated/directives/ng_control_name.ts @@ -8,7 +8,7 @@ import {Directive, Host, Inject, OnChanges, OnDestroy, Optional, Self, SimpleChanges, SkipSelf, forwardRef} from '@angular/core'; -import {EventEmitter, ObservableWrapper} from '../../facade/async'; +import {EventEmitter} from '../../facade/async'; import {Control} from '../model'; import {NG_ASYNC_VALIDATORS, NG_VALIDATORS} from '../validators'; @@ -122,7 +122,7 @@ export class NgControlName extends NgControl implements OnChanges, viewToModelUpdate(newValue: any): void { this.viewModel = newValue; - ObservableWrapper.callEmit(this.update, newValue); + this.update.emit(newValue); } get path(): string[] { return controlPath(this.name, this._parent); } diff --git a/modules/@angular/common/src/forms-deprecated/directives/ng_form.ts b/modules/@angular/common/src/forms-deprecated/directives/ng_form.ts index 23d7f3dd9f..261f7d4ea2 100644 --- a/modules/@angular/common/src/forms-deprecated/directives/ng_form.ts +++ b/modules/@angular/common/src/forms-deprecated/directives/ng_form.ts @@ -8,7 +8,7 @@ import {Directive, Inject, Optional, Self, forwardRef} from '@angular/core'; -import {EventEmitter, ObservableWrapper, PromiseWrapper} from '../../facade/async'; +import {EventEmitter} from '../../facade/async'; import {ListWrapper} from '../../facade/collection'; import {isPresent} from '../../facade/lang'; import {AbstractControl, Control, ControlGroup} from '../model'; @@ -27,6 +27,8 @@ export const formDirectiveProvider: any = { let _formWarningDisplayed: boolean = false; +const resolvedPromise = Promise.resolve(null); + /** * If `NgForm` is bound in a component, `