diff --git a/Sources/OpenSwiftUICore/Layout/Dynamic/DynamicContainer.swift b/Sources/OpenSwiftUICore/Layout/Dynamic/DynamicContainer.swift index 216f0a3a5..2be3f3892 100644 --- a/Sources/OpenSwiftUICore/Layout/Dynamic/DynamicContainer.swift +++ b/Sources/OpenSwiftUICore/Layout/Dynamic/DynamicContainer.swift @@ -611,10 +611,10 @@ struct DynamicContainerInfo: StatefulRule, AsyncAttribute, ObservedAttr let zIndex = infoItem.zIndex hasDepth = hasDepth || (zIndex != 0) if zIndex != info.items[target].zIndex { - info.items[target].zIndex = zIndex + info.items[index].zIndex = zIndex // Weird. No-op actually. changed = true } - if phase != info.items[target].phase { + if phase != info.items[index].phase { changed = true } }