Fix compilation errors in email templates
Update to version v581