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

Remove index on invitations_count column as it's probably not needed by everyone #830

Merged
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Jump to
Jump to file
Failed to load files.
Diff view
Diff view
1 change: 0 additions & 1 deletion lib/generators/active_record/templates/migration.rb
Expand Up @@ -8,7 +8,6 @@ def up
t.integer :invitation_limit
t.references :invited_by, polymorphic: true
t.integer :invitations_count, default: 0
t.index :invitations_count
t.index :invitation_token, unique: true # for invitable
t.index :invited_by_id
end
Expand Down
2 changes: 0 additions & 2 deletions test/rails_app/db/migrate/20100401102949_create_tables.rb
Expand Up @@ -32,7 +32,6 @@ def change
t.timestamps :null => false
end
add_index :users, :invitation_token, :unique => true
add_index :users, :invitations_count

create_table :admins do |t|
## Database authenticatable
Expand All @@ -41,6 +40,5 @@ def change

t.integer :invitations_count, :default => 0
end
add_index :admins, :invitations_count
end
end