fix(ivy): pipes should overwrite pipes with later entry in the pipes array (#27910)

PR Close #27910
This commit is contained in:
Marc Laval
2019-01-03 15:55:01 +01:00
committed by Kara Erickson
parent 13d23f315b
commit 0bd9deb9f5
3 changed files with 46 additions and 10 deletions

View File

@ -55,7 +55,7 @@ export function pipe(index: number, pipeName: string): any {
*/
function getPipeDef(name: string, registry: PipeDefList | null): PipeDef<any> {
if (registry) {
for (let i = 0; i < registry.length; i++) {
for (let i = registry.length - 1; i >= 0; i--) {
const pipeDef = registry[i];
if (name === pipeDef.name) {
return pipeDef;