fix(router): fix CanActivateChild guard provided in a lazy loaded module (#13989)

Closes #12275

PR Close #13989
This commit is contained in:
Dzmitry Shylovich
2017-01-18 18:07:25 +03:00
committed by Miško Hevery
parent 47d41d492b
commit 579567ca79
2 changed files with 42 additions and 1 deletions

View File

@ -961,7 +961,7 @@ export class PreActivation {
return andObservables(map.call(from(canActivateChildGuards), (d: any) => {
const obs = map.call(from(d.guards), (c: any) => {
const guard = this.getToken(c, c.node);
const guard = this.getToken(c, d.node);
let observable: Observable<boolean>;
if (guard.canActivateChild) {
observable = wrapIntoObservable(guard.canActivateChild(future, this.future));