Details
Description
The Bucket#cas operation resets flags
> Couchbase.bucket.set("foo", "bar", :flags => 0x100)
17982951084586893312
> Couchbase.bucket.cas("foo")
1712422461213442048
> Couchbase.bucket.get("foo", :extended => true)
["baz", 0, 1712422461213442048]
So it could be dangerous if someone using custom flags or non-default value encoding (not :document)