Skip to content

set deleted to false instead of unsetting when calling restore()#150

Merged
dsanel merged 1 commit intodsanel:masterfrom
vkarpov15:vkarpov15/mongoose-14338
Nov 6, 2025
Merged

set deleted to false instead of unsetting when calling restore()#150
dsanel merged 1 commit intodsanel:masterfrom
vkarpov15:vkarpov15/mongoose-14338

Conversation

@vkarpov15
Copy link
Copy Markdown
Contributor

Fix Automattic/mongoose#14338

It looks like this commit: b8c3cea made it so that the restore() static would unset deleted versus setting it to false, which is backwards breaking for projects that use use$neOperator: false.

@mareksuscak
Copy link
Copy Markdown
Contributor

I put up another PR that does this before seeing yours. Apologies. Here's mine: #157

@vkarpov15
Copy link
Copy Markdown
Contributor Author

@dsanel would you be open to transferring this project to the mongoosejs GitHub org and handing maintenance over to the Mongoose team? No pressure, this is your project if you want to keep maintaining it, I wanted to ask just in case.

@vkarpov15
Copy link
Copy Markdown
Contributor Author

Hi, just following up on this PR. Is there anything blocking merging and releasing this PR?

@mareksuscak
Copy link
Copy Markdown
Contributor

mareksuscak commented Jul 25, 2025

I'd consider merging the one I opened because this one is not as robust as it doesn't check the status of use$neOperator which could break some flows.

@mareksuscak
Copy link
Copy Markdown
Contributor

But honestly, there's been no response on any issues or PRs in a long time so I think this package needs to be forked by the community at this point.

@dsanel dsanel merged commit 58335ac into dsanel:master Nov 6, 2025
@dsanel
Copy link
Copy Markdown
Owner

dsanel commented Nov 6, 2025

@vkarpov15 Thx!!!

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

Successfully merging this pull request may close these issues.

Model.restore is broken when using use$neOperator = false

3 participants