From b0aa913d513ae21e7cc958c6a3390fa460403e9d Mon Sep 17 00:00:00 2001 From: Peter Burns Date: Mon, 10 Sep 2018 20:00:27 -0700 Subject: [PATCH] Add cast for compilation this._target is an Element, getFlattenedNodes accepts and HTMLElement Upcoming version of closure compiler type checks this better --- lib/utils/flattened-nodes-observer.js | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/lib/utils/flattened-nodes-observer.js b/lib/utils/flattened-nodes-observer.js index 87802d5335..dbbd05d40f 100644 --- a/lib/utils/flattened-nodes-observer.js +++ b/lib/utils/flattened-nodes-observer.js @@ -252,7 +252,8 @@ export class FlattenedNodesObserver { addedNodes: [], removedNodes: [] }; - let newNodes = this.constructor.getFlattenedNodes(this._target); + let newNodes = this.constructor.getFlattenedNodes( + /** @type {!HTMLElement} */ (this._target)); let splices = calculateSplices(newNodes, this._effectiveNodes); // process removals