Error on defining more than one self-referencing discriminated schema #15120
Labels
has repro script
There is a repro script, the Mongoose devs need to confirm that it reproduces the issue
Milestone
Prerequisites
Mongoose version
8.9.1, 8.7.3
Node.js version
18.16.0
MongoDB server version
4.8.1
Typescript version (if applicable)
No response
Description
Defining more than one discriminated schema causes an
Error: Discriminator with name already exists
Steps to Reproduce
Expected Behavior
Should be able to define any number of schemas that self reference.
The text was updated successfully, but these errors were encountered: