fixed some navigation and state issues