should redirect index when not logged in