Skip to content

Commit 9bc67de

Browse files
committed
Clean subviews on setup
1 parent 0ca76af commit 9bc67de

File tree

1 file changed

+3
-0
lines changed

1 file changed

+3
-0
lines changed

Source/AABlurAlertController.swift

Lines changed: 3 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -114,6 +114,9 @@ open class AABlurAlertController: UIViewController {
114114
}
115115

116116
fileprivate func setup() {
117+
// Clean the views
118+
self.view.subviews.forEach{ $0.removeFromSuperview() }
119+
self.backgroundImage.subviews.forEach{ $0.removeFromSuperview() }
117120
// Set up view
118121
self.view.frame = UIScreen.main.bounds
119122
self.view.autoresizingMask = [.flexibleHeight, .flexibleWidth]

0 commit comments

Comments
 (0)