Cope with MESSAGES_DOMAIN not being defined

This commit is contained in:
Tom Hughes 2011-03-16 22:19:35 +00:00
parent bd7a912aa6
commit f8ace8f9e0

View file

@ -116,7 +116,7 @@ class Notifier < ActionMailer::Base
private private
def from_address(name, type, id, digest) def from_address(name, type, id, digest)
if domain = MESSAGES_DOMAIN if Object.const_defined?(:MESSAGES_DOMAIN) and domain = MESSAGES_DOMAIN
"#{name} <#{type}-#{id}-#{digest[0,6]}@#{domain}>" "#{name} <#{type}-#{id}-#{digest[0,6]}@#{domain}>"
else else
EMAIL_FROM EMAIL_FROM