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 encrypt_table for STI #117

Merged
merged 1 commit into from
Jun 20, 2016
Merged

Fix encrypt_table for STI #117

merged 1 commit into from
Jun 20, 2016

Conversation

scottjbarr
Copy link
Contributor

This fix makes encrypt_table! work for STI models.


tmp_table = Class.new(ActiveRecord::Base).tap do |c|
c.table_name = self.table_name
c.inheritance_column = :type_disabled
Copy link
Owner

Choose a reason for hiding this comment

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

What is type_disabled?

Copy link
Collaborator

Choose a reason for hiding this comment

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

@jmazzi this is just a way to disable STI. You set it to a non-existant column and it will be disabled.

Copy link
Owner

Choose a reason for hiding this comment

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

@itspriddle an anti-feature, got it!

@jmazzi jmazzi merged commit 5e10582 into jmazzi:master Jun 20, 2016
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.

None yet

3 participants