Save on Document & ExtendedDocument crashed if bulk
- document#save expects to receive {"ok" => true} even with bulk mode - ExtendedDocument#save_without_callbacks reverted to previous code (expecting result["ok"] as in create_without_callbacks)
This commit is contained in:
parent
1c43a8f3d3
commit
b5d6baaf11
2 changed files with 2 additions and 2 deletions
|
@ -145,7 +145,7 @@ module CouchRest
|
|||
end
|
||||
if bulk
|
||||
@bulk_save_cache << doc
|
||||
return bulk_save if @bulk_save_cache.length >= @bulk_save_cache_limit
|
||||
bulk_save if @bulk_save_cache.length >= @bulk_save_cache_limit
|
||||
return {"ok" => true} # Compatibility with Document#save
|
||||
elsif !bulk && @bulk_save_cache.length > 0
|
||||
bulk_save
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue