diff options
author | Gareth Rees <gareth@mysociety.org> | 2014-04-02 13:48:11 +0100 |
---|---|---|
committer | Gareth Rees <gareth@mysociety.org> | 2014-04-07 17:14:07 +0100 |
commit | 70ef2f4fe5a36fc95a85bed18971cc7c80d54640 (patch) | |
tree | a7232c6059de4d564a83e42d490af5934dd4cd12 | |
parent | 3954e78a4d330e3e9d82be0d239d5bf25d2f6a04 (diff) |
Minor change to FoiAttachment#body_as_html
AttachmentToHTML#to_html already returns the raw html now
-rw-r--r-- | app/models/foi_attachment.rb | 3 |
1 files changed, 1 insertions, 2 deletions
diff --git a/app/models/foi_attachment.rb b/app/models/foi_attachment.rb index 99603ff69..6f46c6785 100644 --- a/app/models/foi_attachment.rb +++ b/app/models/foi_attachment.rb @@ -294,8 +294,7 @@ class FoiAttachment < ActiveRecord::Base # For "View as HTML" of attachment def body_as_html(dir, opts = {}) attachment_url = opts.fetch(:attachment_url, nil) - html = AttachmentToHTML.to_html(self, :tmpdir => dir, :attachment_url => attachment_url) - html.to_s + AttachmentToHTML.to_html(self, :tmpdir => dir, :attachment_url => attachment_url) end end |