Skip to content

Commit

Permalink
fix: bug fix for when having multiple enable-expressions
Browse files Browse the repository at this point in the history
  • Loading branch information
nytamin committed Feb 3, 2021
1 parent 7036e65 commit 5f4ebf6
Showing 1 changed file with 10 additions and 0 deletions.
10 changes: 10 additions & 0 deletions src/resolver/resolver.ts
Original file line number Diff line number Diff line change
Expand Up @@ -546,9 +546,19 @@ export function resolveTimelineObj (resolvedTimeline: ResolvedTimeline, obj: Res
lookedupRepeating,
resolvedTimeline.options
)

instances = instances.concat(newInstances)
}

// Make sure the instance ids are unique:
const ids: {[id: string]: true} = {}
for (const instance of instances ) {
if (ids[instance.id]) {
instance.id = `${instance.id}_${getId()}`
}
ids[instance.id] = true
}

obj.resolved.resolved = true
obj.resolved.resolving = false
obj.resolved.instances = instances
Expand Down

0 comments on commit 5f4ebf6

Please sign in to comment.