Moved replaceMap to utility.string, cleaned up assets shutdown code even more.