ensure molecule is removed from parent

Signed-off-by: Matt Bruce <matt.bruce@verizon.com>
This commit is contained in:
Matt Bruce 2024-04-25 09:07:40 -05:00
parent 725d80b5ce
commit dac8711258

View File

@ -21,7 +21,13 @@ open class TileContainer: VDS.TileContainer, VDSMoleculeViewProtocol{
public var delegateObject: MVMCoreUIDelegateObject?
public var additionalData: [AnyHashable: Any]?
public var molecule: MoleculeViewProtocol?
public var molecule: MoleculeViewProtocol? {
willSet {
if newValue == nil {
molecule?.removeFromSuperview()
}
}
}
//--------------------------------------------------
// MARK: - Initializers