Skip to content
Permalink
Browse files

fix(ngUpgrade): prevent digest already in progress (#9046)

  • Loading branch information...
thelgevold authored and mhevery committed Jun 6, 2016
1 parent 57c9a07 commit d1c989b8a512aaae5e6e1002c58c3a37d6c27153
Showing with 2 additions and 1 deletion.
  1. +1 −0 modules/@angular/upgrade/src/angular_js.ts
  2. +1 −1 modules/@angular/upgrade/src/upgrade_adapter.ts
@@ -26,6 +26,7 @@ export interface IRootScopeService {
$apply(): any;
$apply(exp: string): any;
$apply(exp: Function): any;
$applyAsync(): any;
$$childTail: IScope;
$$childHead: IScope;
$$nextSibling: IScope;
@@ -366,7 +366,7 @@ export class UpgradeAdapter {
(injector: angular.IInjectorService, rootScope: angular.IRootScopeService) => {
ng1Injector = injector;
ngZone.onMicrotaskEmpty.subscribe(
{next: (_) => ngZone.runOutsideAngular(() => rootScope.$apply())});
{next: (_) => ngZone.runOutsideAngular(() => rootScope.$applyAsync())});
UpgradeNg1ComponentAdapterBuilder.resolve(this.downgradedComponents, injector)
.then(resolve, reject);
}

0 comments on commit d1c989b

Please sign in to comment.
You can’t perform that action at this time.