X-Git-Url: https://git.openstreetmap.org/rails.git/blobdiff_plain/774e583b20555c4ad9f676a6321169ff3482980a..cca78f979060e6c8fd4ffcbf58a2e3361502aa99:/app/helpers/notifier_helper.rb diff --git a/app/helpers/notifier_helper.rb b/app/helpers/notifier_helper.rb index 5889b6ff8..23ee45648 100644 --- a/app/helpers/notifier_helper.rb +++ b/app/helpers/notifier_helper.rb @@ -18,4 +18,11 @@ module NotifierHelper :locals => { :body => capture(&block) } ) end + + def style_message(html) + # Because we can't use stylesheets in HTML emails, we need to inline the + # styles. Rather than copy-paste the same string of CSS into every message, + # we apply it once here, after the message has been composed. + html.gsub /

/, '

' + end end