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

hasOne association doesn't use the 'as' alias for constructing foreign keys #5247

Closed
rmzg opened this issue Jan 18, 2016 · 0 comments
Closed
Labels
breaking change For issues and PRs. Changes that break compatibility and require a major version increment.
Milestone

Comments

@rmzg
Copy link
Contributor

rmzg commented Jan 18, 2016

https://github.com/sequelize/sequelize/blob/master/lib/associations/has-one.js#L50

The code for constructing the default name for the targetKey in hasOne associations should use the options.as alias before using the target.name.

@mickhansen mickhansen added the breaking change For issues and PRs. Changes that break compatibility and require a major version increment. label Jan 18, 2016
@mickhansen mickhansen added this to the 4.0 milestone Jan 18, 2016
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
breaking change For issues and PRs. Changes that break compatibility and require a major version increment.
Projects
None yet
Development

No branches or pull requests

2 participants