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: preload panic when model and dest different #5130

Closed
wants to merge 3 commits into from

Conversation

a631807682
Copy link
Member

  • Do only one thing
  • Non breaking API changes
  • Tested

What did this pull request do?

Preload will panic when Mode and Dest is different schema.

 DB.Model(User{}).Preload("Account").Select("users.*, 'yo' as something").First(&result, user.ID).

close #4886

@a631807682
Copy link
Member Author

I don't know why the test will fail when i move the test func to the end of file.

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.

panic when preload substruct of nested struct
1 participant