-
Notifications
You must be signed in to change notification settings - Fork 13
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 conflict with existing add_foreign_key method (#1) #6
base: rails-4-2
Are you sure you want to change the base?
Conversation
@@ -222,7 +222,7 @@ def unique_index_name(name, *partition_key_values) | |||
# | |||
def add_references_to_partition_table(*partition_key_values) | |||
configurator.foreign_keys(*partition_key_values).each do |foreign_key| | |||
add_foreign_key(partition_table_name(*partition_key_values), | |||
add_foreign_key_constraint(partition_table_name(*partition_key_values), |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Style comment: Would you mind fixing the indents of rest of the arguments being passed in in the next few lines?
@@ -281,7 +281,7 @@ def unique_index_name(name, *partition_key_values) | |||
# | |||
def add_references_to_partition_table(*partition_key_values) | |||
configurator.foreign_keys(*partition_key_values).each do |foreign_key| | |||
add_foreign_key(partition_table_name(*partition_key_values), | |||
add_foreign_key_constraint(partition_table_name(*partition_key_values), | |||
foreign_key.referencing_field, |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Same comment as above, can you fix the indents here?
Couple style comments, otherwise looks good. |
Previously this was causing an error because ActiveRecord has a add_foreign_key method with a different signature. This solution was submitted by someone else in a PR at dkhofer#6, but was left unmerged.
No description provided.