Skip to content
Browse files

Use replace in save method. Thanks to @scalabl3

Change-Id: I07681751de76a5e7a2b9a40a0ed899ea57be23c6
  • Loading branch information...
1 parent d6c879d commit 740b99f060cbaef9f22c596bf7032204454de2f7 @avsej committed Sep 19, 2012
Showing with 1 addition and 1 deletion.
  1. +1 −1 lib/couchbase/model.rb
View
2 lib/couchbase/model.rb
@@ -456,7 +456,7 @@ def create
# p.save
def save(cas = nil)
return create if new?
- model.bucket.set(@id, attributes_with_values, :cas => cas)
+ model.bucket.replace(@id, attributes_with_values, :cas => cas)
self
end

0 comments on commit 740b99f

Please sign in to comment.
Something went wrong with that request. Please try again.