Merge remote branch 'tapajos/master'
Conflicts: README.md lib/couchrest/mixins/properties.rb spec/couchrest/core/database_spec.rb spec/couchrest/more/extended_doc_spec.rb
This commit is contained in:
commit
2f2c507582
11 changed files with 47 additions and 11 deletions
|
@ -64,7 +64,7 @@ module CouchRest
|
|||
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
|
||||
|
|
|
@ -245,6 +245,7 @@ module CouchRest
|
|||
# if the document is not saved properly.
|
||||
def save!
|
||||
raise "#{self.inspect} failed to save" unless self.save
|
||||
true
|
||||
end
|
||||
|
||||
# Deletes the document from the database. Runs the :destroy callbacks.
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue