Fix issue with container not always hiding. Simplify