minor fix on remove stack view's subviews

pull/638/head
Ryan Zhao 4 years ago
parent 9d795d4bfb
commit acddafd131

@ -32,6 +32,7 @@ final class ReactionContainerView : UIView {
public func update(_ reactions: [(String, (Int, Bool))]) { public func update(_ reactions: [(String, (Int, Bool))]) {
for subview in containerView.arrangedSubviews { for subview in containerView.arrangedSubviews {
containerView.removeArrangedSubview(subview) containerView.removeArrangedSubview(subview)
subview.removeFromSuperview()
} }
let stackView = UIStackView() let stackView = UIStackView()
stackView.axis = .horizontal stackView.axis = .horizontal

Loading…
Cancel
Save