aboutsummaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
-rw-r--r--app/models/incoming_message.rb3
-rw-r--r--app/models/request_mailer.rb4
2 files changed, 5 insertions, 2 deletions
diff --git a/app/models/incoming_message.rb b/app/models/incoming_message.rb
index c354a8554..030a2c04a 100644
--- a/app/models/incoming_message.rb
+++ b/app/models/incoming_message.rb
@@ -19,7 +19,7 @@
# Copyright (c) 2007 UK Citizens Online Democracy. All rights reserved.
# Email: francis@mysociety.org; WWW: http://www.mysociety.org/
#
-# $Id: incoming_message.rb,v 1.141 2008-09-01 16:09:18 francis Exp $
+# $Id: incoming_message.rb,v 1.142 2008-09-04 11:11:38 francis Exp $
# TODO
# Move some of the (e.g. quoting) functions here into rblib, as they feel
@@ -69,6 +69,7 @@ module TMail
return text
end
+ # Monkeypatch!
def quoted_full
if self.name
Address.encode_quoted_string(self.name) + " <" + self.spec + ">"
diff --git a/app/models/request_mailer.rb b/app/models/request_mailer.rb
index 1a93051e1..a0b5ba70e 100644
--- a/app/models/request_mailer.rb
+++ b/app/models/request_mailer.rb
@@ -4,7 +4,7 @@
# Copyright (c) 2007 UK Citizens Online Democracy. All rights reserved.
# Email: francis@mysociety.org; WWW: http://www.mysociety.org/
#
-# $Id: request_mailer.rb,v 1.55 2008-09-04 06:20:00 francis Exp $
+# $Id: request_mailer.rb,v 1.56 2008-09-04 11:11:40 francis Exp $
class RequestMailer < ApplicationMailer
@@ -31,6 +31,7 @@ class RequestMailer < ApplicationMailer
if incoming_message_followup.nil?
return info_request.recipient_name_and_email
else
+ IncomingMessage # get Monkeypatch!
return incoming_message_followup.mail.from_addrs[0].quoted_full
end
end
@@ -70,6 +71,7 @@ class RequestMailer < ApplicationMailer
# Incoming message arrived for a request, but new responses have been stopped.
def stopped_responses(info_request, email)
@from = contact_from_name_and_email
+ IncomingMessage # get Monkeypatch!
@recipients = email.from_addrs[0].quoted_full
@subject = "Your response to an FOI request was not delivered"
attachment :content_type => 'message/rfc822', :body => email.body