Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Each document that gets queried before save #11

Open
janober opened this issue Feb 3, 2015 · 1 comment
Open

Each document that gets queried before save #11

janober opened this issue Feb 3, 2015 · 1 comment

Comments

@janober
Copy link

janober commented Feb 3, 2015

Just looked through "updateOneDoc" in "lib/cb.js". Saw that before each document gets saved it gets queried first and then the new data merged with the existing one.
The reason seems to be to preserve id & type. Is that the only reason or did I overlook something?

Because I do not think it is really necessary for that. The id is given anyway and we also have the model in there alreay. So they can simply be set without the whole querying and merging.

@janober
Copy link
Author

janober commented Feb 5, 2015

Wanted to fix that issue together with the cas one but because of the couchbase-bugs I could not. So I did now just commit the change to fix that issue. If interested here is the comit (again no pull request for the same reason as before):
janober@7f8078b

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

1 participant