aboutsummaryrefslogtreecommitdiffstats
path: root/db
diff options
context:
space:
mode:
authorHenare Degan <henare.degan@gmail.com>2013-02-15 17:40:04 +1100
committerHenare Degan <henare.degan@gmail.com>2013-02-15 17:59:06 +1100
commita0f250204a376ce97a187cf8a9b2cb0b8c628298 (patch)
tree812504a7b8da2431b3fed6f38f6796cdbbc84e00 /db
parent8f1caab7990dc417e32b14cbb5f00c34a0ddc10c (diff)
parentd16f2f8242352a2d3c0350275110453dd6ac6b12 (diff)
Merge branch 'develop' into rails-3-spike
Conflicts: Gemfile Gemfile.lock app/controllers/general_controller.rb app/controllers/track_controller.rb app/models/outgoing_message.rb app/models/public_body.rb app/models/user.rb app/views/general/frontpage.rhtml config/environment.rb config/initializers/inflections.rb config/initializers/mime_types.rb db/migrate/094_remove_old_tags_foreign_key.rb lib/timezone_fixes.rb spec/models/request_mailer_spec.rb spec/views/request/list.rhtml_spec.rb
Diffstat (limited to 'db')
-rw-r--r--db/migrate/094_remove_old_tags_foreign_key.rb6
1 files changed, 2 insertions, 4 deletions
diff --git a/db/migrate/094_remove_old_tags_foreign_key.rb b/db/migrate/094_remove_old_tags_foreign_key.rb
index 839f76334..5a6a00acc 100644
--- a/db/migrate/094_remove_old_tags_foreign_key.rb
+++ b/db/migrate/094_remove_old_tags_foreign_key.rb
@@ -2,12 +2,10 @@ class RemoveOldTagsForeignKey < ActiveRecord::Migration
def self.up
if ActiveRecord::Base.connection.adapter_name == "PostgreSQL"
execute "ALTER TABLE has_tag_string_tags DROP CONSTRAINT fk_public_body_tags_public_body"
+ execute 'DROP INDEX index_public_body_tags_on_public_body_id_and_name_and_value'
+ execute 'DROP INDEX index_public_body_tags_on_name'
end
- # This table was already removed in the previous migration
- # remove_index :public_body_tags, [:public_body_id, :name, :value]
- # remove_index :public_body_tags, :name
-
add_index :has_tag_string_tags, [:model, :model_id, :name, :value], :name => 'by_model_and_model_id_and_name_and_value'
add_index :has_tag_string_tags, :name
end