aboutsummaryrefslogtreecommitdiffstats
path: root/app/models
diff options
context:
space:
mode:
Diffstat (limited to 'app/models')
-rw-r--r--app/models/info_request.rb10
-rw-r--r--app/models/info_request_event.rb3
-rw-r--r--app/models/public_body.rb2
3 files changed, 6 insertions, 9 deletions
diff --git a/app/models/info_request.rb b/app/models/info_request.rb
index aaced91a2..eba620f53 100644
--- a/app/models/info_request.rb
+++ b/app/models/info_request.rb
@@ -271,15 +271,9 @@ public
# Subject lines for emails about the request
def email_subject_request
- # XXX pull out this general_register_office specialisation
- # into some sort of separate jurisdiction dependent file
- if self.public_body.url_name == 'general_register_office'
- # without GQ in the subject, you just get an auto response
- _('{{law_used_full}} request GQ - {{title}}',:law_used_full=>self.law_used_full,:title=>self.title.html_safe)
- else
- _('{{law_used_full}} request - {{title}}',:law_used_full=>self.law_used_full,:title=>self.title.html_safe)
- end
+ _('{{law_used_full}} request - {{title}}',:law_used_full=>self.law_used_full,:title=>self.title.html_safe)
end
+
def email_subject_followup(incoming_message = nil)
if incoming_message.nil? || !incoming_message.valid_to_reply_to? || !incoming_message.subject
'Re: ' + self.email_subject_request
diff --git a/app/models/info_request_event.rb b/app/models/info_request_event.rb
index 67cdda1b4..e268b28ca 100644
--- a/app/models/info_request_event.rb
+++ b/app/models/info_request_event.rb
@@ -339,6 +339,9 @@ class InfoRequestEvent < ActiveRecord::Base
end
raise _("unknown status ") + status
end
+ # TRANSLATORS: "Follow up" in this context means a further
+ # message sent by the requester to the authority after
+ # the initial request
return _("Follow up")
end
diff --git a/app/models/public_body.rb b/app/models/public_body.rb
index 828e8c94a..485a794b0 100644
--- a/app/models/public_body.rb
+++ b/app/models/public_body.rb
@@ -71,7 +71,7 @@ class PublicBody < ActiveRecord::Base
def PublicBody.set_first_letter(instance)
unless instance.name.nil? or instance.name.empty?
# we use a regex to ensure it works with utf-8/multi-byte
- first_letter = instance.name.scan(/^./mu)[0].upcase
+ first_letter = Unicode.upcase instance.name.scan(/^./mu)[0]
if first_letter != instance.first_letter
instance.first_letter = first_letter
end