user_template_xml was returning the whole template instead of the user template

(cherry picked from commit 8f29000d35143f52f05258871feb1a6e927a36fe)