remove clones every time a template is set