aboutsummaryrefslogtreecommitdiffstats
path: root/app/models
diff options
context:
space:
mode:
Diffstat (limited to 'app/models')
-rw-r--r--app/models/incoming_message.rb6
1 files changed, 5 insertions, 1 deletions
diff --git a/app/models/incoming_message.rb b/app/models/incoming_message.rb
index 6d37ab01d..8aaaa66e6 100644
--- a/app/models/incoming_message.rb
+++ b/app/models/incoming_message.rb
@@ -17,7 +17,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.73 2008-04-04 01:44:41 francis Exp $
+# $Id: incoming_message.rb,v 1.74 2008-04-14 15:45:01 francis Exp $
# TODO
@@ -56,6 +56,8 @@ class FOIAttachment
"attachment.pdf"
elsif @content_type == 'application/msword'
"attachment.doc"
+ elsif @content_type == 'application/msexcel'
+ "attachment.xls"
else
"attachment.bin"
end
@@ -335,6 +337,8 @@ class IncomingMessage < ActiveRecord::Base
attachment.content_type = 'application/pdf'
elsif attachment.filename.match(/\.doc$/)
attachment.content_type = 'application/msword'
+ elsif attachment.filename.match(/\.xls$/)
+ attachment.content_type = 'application/msexcel'
else
attachment.content_type = 'application/octet-stream'
end