From b9de0892797309695eb422e0500c4121a3701918 Mon Sep 17 00:00:00 2001 From: Anton Argirov Date: Thu, 1 Oct 2015 10:25:29 +0600 Subject: [PATCH] Fixed error in Mailer#custom_email occuring when :template_params are not passed in headers --- lib/redmine_custom_workflows/mailer_patch.rb | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/lib/redmine_custom_workflows/mailer_patch.rb b/lib/redmine_custom_workflows/mailer_patch.rb index 4fa906d..863ed23 100644 --- a/lib/redmine_custom_workflows/mailer_patch.rb +++ b/lib/redmine_custom_workflows/mailer_patch.rb @@ -14,7 +14,7 @@ module RedmineCustomWorkflows text_body = headers.delete :text_body html_body = headers.delete :html_body template_name = headers.delete :template_name - template_params = headers.delete :template_params || {} + template_params = headers.delete(:template_params) || {} if text_body || html_body mail headers do |format| format.text { render :text => text_body } if text_body