Removing non-templates