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

Unexpected behaviour when upgrading to mongoose 6 with mutation resolvers #381

Open
trollcus opened this issue Sep 21, 2021 · 1 comment

Comments

@trollcus
Copy link

trollcus commented Sep 21, 2021

When updating a nested field with a updateOne resolver, all the other field in that same object field becomes null.

let's say we have:

basic_info {
size
email
}

when updating one of the fields, the other ones becomes null.

Had to downgrade to mongoose 5 for now as it's working as expected there.

@trollcus trollcus changed the title Unexpected behaviour when upgrading to mongoose 6 Unexpected behaviour when upgrading to mongoose 6 with mutation resolvers Sep 21, 2021
@steverogers180
Copy link

Send the whole document with an updated field. That's the only solution for now until someone fixes this.

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

2 participants