Fix renaming resources with a dash in the name.