fix(router): merge SystemJsAppModuleFactoryLoader and SystemJsAllModuleLoader

This commit is contained in:
vsavkin
2016-07-13 10:39:16 -07:00
parent 0b54e3cf0a
commit 0426325ef7
6 changed files with 21 additions and 30 deletions

View File

@ -291,11 +291,9 @@ export class Router {
const tree = this.urlSerializer.parse(change['url']);
// we fire multiple events for a single URL change
// we should navigate only once
if (this.currentUrlTree.toString() !== tree.toString()) {
return this.scheduleNavigation(tree, change['pop']);
} else {
return null;
}
return this.currentUrlTree.toString() !== tree.toString() ?
this.scheduleNavigation(tree, change['pop']) :
null;
});
}