about summary refs log tree commit diff
path: root/db/migrate
diff options
context:
space:
mode:
authorEugen Rochko <eugen@zeonfederated.com>2017-08-30 05:04:20 +0200
committerGitHub <noreply@github.com>2017-08-30 05:04:20 +0200
commitfcca31350d05064a117c5f1c1b014875dc12afd3 (patch)
treece1e6873453c127d49b8e72bac86fa235a23cb36 /db/migrate
parentee72a396417c9a2f9ec44732f58a8a4ab43d11b8 (diff)
Remove unneccesary indices (#4738)
We only look up status_pins by account_id, or account_id and status_id,
never by status_id
Diffstat (limited to 'db/migrate')
-rw-r--r--db/migrate/20170829215220_remove_status_pins_account_index.rb6
1 files changed, 6 insertions, 0 deletions
diff --git a/db/migrate/20170829215220_remove_status_pins_account_index.rb b/db/migrate/20170829215220_remove_status_pins_account_index.rb
new file mode 100644
index 000000000..e0144242e
--- /dev/null
+++ b/db/migrate/20170829215220_remove_status_pins_account_index.rb
@@ -0,0 +1,6 @@
+class RemoveStatusPinsAccountIndex < ActiveRecord::Migration[5.1]
+  def change
+    remove_index :status_pins, :account_id
+    remove_index :status_pins, :status_id
+  end
+end