cleaning search templates