refactoring xsl