Exception -> StandardError

This commit is contained in:
Karel Pičman 2020-01-14 14:24:36 +01:00
parent c8eefcaa3f
commit 00c24d580b

View File

@ -33,8 +33,8 @@ module RedmineCustomWorkflows
template_params = headers.delete(:template_params) || {}
if text_body || html_body
mail headers do |format|
format.text { render :text => text_body } if text_body
format.html { render :text => html_body } if html_body
format.text { render text: text_body } if text_body
format.html { render text: html_body } if html_body
end
elsif template_name
template_params.each { |k,v| instance_variable_set("@#{k}", v) }
@ -43,7 +43,7 @@ module RedmineCustomWorkflows
format.html { render template_name } unless Setting.plain_text_mail?
end
else
raise 'Not :text_body, :html_body or :template_name specified'
raise StandardError.new('Not :text_body, :html_body or :template_name specified')
end
end