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

Auto-increment has been done in case of document conflict #32

Open
OhDavit opened this issue Feb 22, 2018 · 4 comments
Open

Auto-increment has been done in case of document conflict #32

OhDavit opened this issue Feb 22, 2018 · 4 comments

Comments

@OhDavit
Copy link

OhDavit commented Feb 22, 2018

I have a collection with lets say X auto increment field and which has also compound unique index. So in case of duplication of fields save method returns 409 error, but X field has been incremented.
The expected behavior would be to increment X field only when document is saved in the collection.

@ramiel
Copy link
Owner

ramiel commented Feb 23, 2018

I think you're right. I have to remember why I chose to use the 'pre' middleware. I'll be back to this, soon

@Leeiio
Copy link

Leeiio commented Jan 23, 2019

@ramiel any updates to solve this issue?

@wilav-dev
Copy link

Same issue

@ramiel
Copy link
Owner

ramiel commented Jan 7, 2022

Not really. Can you provide a little reproduction repo?

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

4 participants