Browse files

Correctly set content_type when adding an attachment.

Signed-off-by: Arnaud Berthomier <oz@cyprio.net>
  • Loading branch information...
1 parent 2f4edb7 commit 87822f70e21319a7dd06d3e2ea61573e2e994ed6 @dwalters dwalters committed with May 7, 2009
Showing with 1 addition and 1 deletion.
  1. +1 −1 lib/couchrest/mixins/extended_attachments.rb
View
2 lib/couchrest/mixins/extended_attachments.rb
@@ -64,7 +64,7 @@ def get_mime_type(file)
def set_attachment_attr(args)
content_type = args[:content_type] ? args[:content_type] : get_mime_type(args[:file])
self['_attachments'][args[:name]] = {
- 'content-type' => content_type,
+ 'content_type' => content_type,
'data' => encode_attachment(args[:file].read)
}
end

0 comments on commit 87822f7

Please sign in to comment.