changed ensure to file for file resources