Fix for view being accessed to early