Added the option to check if asset exists