correctly use resolve to check session before page loading