Try to fix nested template.