You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Describe the bug
After upgrading from v5.3.1 to v5.4.1 of mikro-orm I get a ValidationError while populating an Entity.
Stack trace
ValidationError: Entity 'Contract' does not have property 'contracts'
at Function.invalidPropertyName (***/node_modules/@mikro-orm/core/errors.js:53:16)
at SqlEntityManager.preparePopulate (***/node_modules/@mikro-orm/core/EntityManager.js:855:44)
at SqlEntityManager.lockAndPopulate (***/node_modules/@mikro-orm/core/EntityManager.js:815:39)
at SqlEntityManager.findOne (***/node_modules/@mikro-orm/core/EntityManager.js:317:22)
at processTicksAndRejections (node:internal/process/task_queues:95:5)
at SqlEntityManager.findOneOrFail (***/node_modules/@mikro-orm/core/EntityManager.js:338:22)
at getUnlockedEmployeesForContract (***/src/services/employeeService/getUnlockedEmployeesForContract.ts:32:22) {
entity: undefined
}
It seems like it is detecting the childCustomer property as a Contract, even though it is a Customer.
If needed i can provide a working minimal example repository.
Versions
Dependency
Version
node
v18.8.0
typescript
4.8.3
mikro-orm
5.4.1
The text was updated successfully, but these errors were encountered:
Describe the bug
After upgrading from v5.3.1 to v5.4.1 of mikro-orm I get a ValidationError while populating an Entity.
Stack trace
To Reproduce
Minimal example:
It seems like it is detecting the childCustomer property as a Contract, even though it is a Customer.
If needed i can provide a working minimal example repository.
Versions
The text was updated successfully, but these errors were encountered: