fix rootPath var