about summary refs log tree commit diff stats
diff options
context:
space:
mode:
authorKelly Rauchenberger <fefferburbia@gmail.com>2017-10-15 14:18:07 -0400
committerKelly Rauchenberger <fefferburbia@gmail.com>2017-10-15 14:18:07 -0400
commitc2fe86394bac998d887c5f59b48849dc067b9e43 (patch)
treef401509414ab61f5017a08ce496d5b3c00e167f1
parent23be60788864b1c47c06dffc1e647a5c29793ca0 (diff)
downloadthoughts-c2fe86394bac998d887c5f59b48849dc067b9e43.tar.gz
thoughts-c2fe86394bac998d887c5f59b48849dc067b9e43.tar.bz2
thoughts-c2fe86394bac998d887c5f59b48849dc067b9e43.zip
Fixed MySQL choking on a pokeviewer migration
See hatkirby/pokeviewer@a29b86011d9c53709279d125f4501140c17ccc1e.
-rw-r--r--Gemfile.lock2
-rw-r--r--db/migrate/20171015171554_rename_revision_hold_item.pokeviewer.rb4
2 files changed, 4 insertions, 2 deletions
diff --git a/Gemfile.lock b/Gemfile.lock index 28066a4..108fb43 100644 --- a/Gemfile.lock +++ b/Gemfile.lock
@@ -1,6 +1,6 @@
1GIT 1GIT
2 remote: https://github.com/hatkirby/pokeviewer.git 2 remote: https://github.com/hatkirby/pokeviewer.git
3 revision: 39a065e9cabdff4d90025ac0090b64aea6941a9d 3 revision: a29b86011d9c53709279d125f4501140c17ccc1e
4 specs: 4 specs:
5 pokeviewer (0.1.0) 5 pokeviewer (0.1.0)
6 activerecord-diff 6 activerecord-diff
diff --git a/db/migrate/20171015171554_rename_revision_hold_item.pokeviewer.rb b/db/migrate/20171015171554_rename_revision_hold_item.pokeviewer.rb index f7246de..d83f5e8 100644 --- a/db/migrate/20171015171554_rename_revision_hold_item.pokeviewer.rb +++ b/db/migrate/20171015171554_rename_revision_hold_item.pokeviewer.rb
@@ -1,8 +1,10 @@
1# This migration comes from pokeviewer (originally 20170930213633) 1# This migration comes from pokeviewer (originally 20170930213633)
2class RenameRevisionHoldItem < ActiveRecord::Migration[5.1] 2class RenameRevisionHoldItem < ActiveRecord::Migration[5.1]
3 def change 3 def change
4 remove_column :pokeviewer_revisions, :hold_item, :integer
5
4 change_table :pokeviewer_revisions do |t| 6 change_table :pokeviewer_revisions do |t|
5 t.rename :hold_item, :item_id 7 t.integer :item_id
6 end 8 end
7 9
8 add_foreign_key :pokeviewer_revisions, :pokeviewer_items, column: :item_id 10 add_foreign_key :pokeviewer_revisions, :pokeviewer_items, column: :item_id