From 925e654a29518c5fcf8a8540fadd0a1045e14931 Mon Sep 17 00:00:00 2001 From: Patrick Shields Date: Tue, 16 Jan 2018 15:09:51 -0600 Subject: [PATCH] fix(router): don't use ParamsInheritanceStrategy in declarations (#21574) ParamsInheritanceStrategy is internal, so any references to it from the published .d.ts files will fail. Fixes #21456. PR Close #21574 --- packages/router/src/pre_activation.ts | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) diff --git a/packages/router/src/pre_activation.ts b/packages/router/src/pre_activation.ts index 00c68936bd..c3e9895d00 100644 --- a/packages/router/src/pre_activation.ts +++ b/packages/router/src/pre_activation.ts @@ -21,7 +21,7 @@ import {reduce} from 'rxjs/operator/reduce'; import {LoadedRouterConfig, ResolveData, RunGuardsAndResolvers} from './config'; import {ActivationStart, ChildActivationStart, Event} from './events'; import {ChildrenOutletContexts, OutletContext} from './router_outlet_context'; -import {ActivatedRouteSnapshot, ParamsInheritanceStrategy, RouterStateSnapshot, equalParamsAndUrlSegments, inheritedParamsDataResolve} from './router_state'; +import {ActivatedRouteSnapshot, RouterStateSnapshot, equalParamsAndUrlSegments, inheritedParamsDataResolve} from './router_state'; import {andObservables, forEach, shallowEqual, wrapIntoObservable} from './utils/collection'; import {TreeNode, nodeChildrenAsMap} from './utils/tree'; @@ -63,7 +63,7 @@ export class PreActivation { (canDeactivate: boolean) => canDeactivate ? this.runCanActivateChecks() : of (false)); } - resolveData(paramsInheritanceStrategy: ParamsInheritanceStrategy): Observable { + resolveData(paramsInheritanceStrategy: 'emptyOnly'|'always'): Observable { if (!this.isActivating()) return of (null); const checks$ = from(this.canActivateChecks); const runningChecks$ = concatMap.call( @@ -308,7 +308,7 @@ export class PreActivation { private runResolve( future: ActivatedRouteSnapshot, - paramsInheritanceStrategy: ParamsInheritanceStrategy): Observable { + paramsInheritanceStrategy: 'emptyOnly'|'always'): Observable { const resolve = future._resolve; return map.call(this.resolveNode(resolve, future), (resolvedData: any): any => { future._resolvedData = resolvedData;