-
Notifications
You must be signed in to change notification settings - Fork 21
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
Adding lean() causes TypeError: document.data is not a function #77
Comments
Hey @jamesholcomb, I think we can support this. I'll have a deeper look over the weekend. |
Additionally, specifying A simple test already exists for |
Hey @jamesholcomb i know some time has passed by I finally made the time to dig through all open issues. Hopefully you still somewhat know what this was about. In my understanding A simple fix would then be to state it in the README and disable the plugin hooks if |
I ended up refactoring my code by removing Would it be more useful to throw an error if the lib detects either of those options? |
Thanks for answering! Then I would propose throwing an error and providing a config option to disable error throwing? |
Perhaps you could expand on the behavior of 'disable the plugin hooks' |
Under |
From an end user perspective, it is hard to imagine a scenario where you would explicitly configure a collection for patch history but disable the plugin if your db writes utilize those mongoose options. Especially If you go with a "throw on error" style option, it would be prudent to enable by default. |
Isn't Just some quick thoughts on this, I'll need to consult mongoose documentation ..
So the option would rather be |
Tested with https://github.com/codepunkt/mongoose-patch-history#b9d8abde29d0b1df5137f8c4565a73069aeff3d0
Perhaps this cannot be supported and should be mentioned in the README?
The text was updated successfully, but these errors were encountered: