From a619f902a3c6f95e486f4886ac7cc41ae778c8db Mon Sep 17 00:00:00 2001 From: Vikram Subramanian Date: Tue, 20 Mar 2018 06:58:54 -0700 Subject: [PATCH] fix(router): don't use spread operator to workaround an issue in closure compiler Closure compiler could not handle the spread operator in this one place. Working around it by removing the use of spread operator. --- packages/router/src/utils/collection.ts | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/packages/router/src/utils/collection.ts b/packages/router/src/utils/collection.ts index 2be7ff2d263aa..dd1ccadebed00 100644 --- a/packages/router/src/utils/collection.ts +++ b/packages/router/src/utils/collection.ts @@ -84,7 +84,8 @@ export function waitForMap( } }); - return of (...waitHead, ...waitTail).pipe(concatAll(), lastValue(), map(() => res)); + // Closure compiler has problem with using spread operator here. So just using Array.concat. + return of .apply(null, waitHead.concat(waitTail)).pipe(concatAll(), lastValue(), map(() => res)); } /**