-
-
Notifications
You must be signed in to change notification settings - Fork 1.1k
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
Allow #[diesel(treat_none_as_{null, default_value} = …]
on fields
#3724
Conversation
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.
Need tests, both happy and error cases.
I've added/modified tests to exercise field-level However, I didn't see any pre-existing tests for |
Something I just thought about: as implemented, putting an explicit |
yes that makes sense, that would be better |
If present on a field, this will override the corresponding container-level attribute.
a7b99ae
to
bb707bf
Compare
I've rebased this branch to pull in the changes from #3729 to fix the broken tests. |
If present on a field, this will override the corresponding container-level attribute.
This restores feature parity with the old
diesel 1.x
versions, which allowed these two attributes on struct fields.