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

HABTM associations now honor the auto_include option #35

Closed
wants to merge 2 commits into from

Conversation

jturkel
Copy link
Member

@jturkel jturkel commented Aug 5, 2016

This fixes #34

@mattcross - Mind taking a quick look?


def has_and_belongs_to_many_with_auto_include_option(name, scope = nil, options = {}, &extension)
if scope.is_a?(Hash)
options = scope

Choose a reason for hiding this comment

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

Should this be a merge?

Copy link
Member Author

Choose a reason for hiding this comment

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

No. I need to replicate the logic from /~https://github.com/rails/rails/blob/master/activerecord/lib/active_record/associations.rb#L1789 so I can use the options hash.

@mattcross
Copy link

🚢 assuming that scope/options replacement is correct.

@jturkel jturkel closed this in 9b7b0e4 Aug 5, 2016
@jturkel jturkel deleted the feature/issue-34 branch December 15, 2016 14:52
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.

auto_include: false isn't honored with HABTM
2 participants