Fixes bug with custom view not being removed from superview when set nil