MichalLytek / MichalLytek/type-graphql
Returning deeply extended type from inteface query
Open
Bug :bug:
- Dominant language
- TypeScript
- Stars
- 8.1k
- Forks
- 672
- PR merge metrics
- No merged PRs in 30d
Description
#279 added support for returning plain object from queries which returns type is an interface but it introduced a regression that makes `interfaces-inheritance` example not working correctly.
The `implementingObjectTypesTargets` looks for classes that implements selected interface but because of current pipeline limitation (#183) it doesn't have access to parent and its parent classes metadata, so when using deeply nested inheritance, it might return the first (base) class always.
The workaround for now is to use custom `resolveType` functions.
Contributor guide
Assessment
This issue has not been assessed yet.