Null checks for Container.

#2030