Skip to content
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/case when fk is pointer #38

Merged
merged 3 commits into from
Sep 21, 2024
Merged

Fix/case when fk is pointer #38

merged 3 commits into from
Sep 21, 2024

Conversation

eyo-chen
Copy link
Owner

  • fix the case when foreign key is pointer

Comment on lines 342 to 344
if target.IsNil() {
target.Set(reflect.New(target.Type().Elem()))
}
Copy link
Owner Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

this condition is unnecessary because all the field will be set with non-zero value by setAssValue

@eyo-chen eyo-chen merged commit 819105d into main Sep 21, 2024
3 checks passed
@eyo-chen eyo-chen deleted the fix/case-when-fk-is-pointer branch September 21, 2024 00:08
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

1 participant