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
fix: resolve get entity value for date columns that are related #8027
fix: resolve get entity value for date columns that are related #8027
Conversation
This needs a test to confirm the behavior |
…peorm into fix-related-date-insert
@imnotjames I added a test. Will it be an issue that my last commit message is a merge? |
No, it's all gravy. We'll probably squash it. |
We dealt with something similar in #7774 - where only plain objects were treated with this. Possibly tangentially related kinds of issues. I'll try to get to actually reviewing this sooner rather than later. |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
This is fine for now. We probably want to make this more general in the future but I think it'll help your exact issue.
In particular, we should really be checking the metadata to confirm that this property is either a plain object or a registered embedded type & failing otherwise.
It does feel like a bandage on a larger issue but I'm very new to TypeORM so I haven't had the time to really understand what the proper fix looks like. If I stick with TypeORM for future work I'll be happy to circle back and submit a better patch in the future. |
Closes: #8026
Description of change
Allows for date columns that are part of a relation to have data inserted into them.
Fixes: #8026
Pull-Request Checklist
master
branchnpm run lint
passes with this changenpm run test
passes with this changeFixes #0000