Fix "template not found" for custom templates.