ECMS-5611 clean spaces in the template name