mirror of
https://github.com/TracksApp/tracks.git
synced 2025-12-27 04:18:49 +01:00
fix migration for rollback
This commit is contained in:
parent
9000dca33a
commit
29f28db810
1 changed files with 1 additions and 1 deletions
|
|
@ -16,7 +16,7 @@ class AddStateToContext < ActiveRecord::Migration
|
|||
def down
|
||||
add_column :contexts, :hide, :boolean, :default => false
|
||||
Context.reset_column_information
|
||||
Context.all.each { |c| c.hide = ( c.state == 'hidden' ) }
|
||||
Context.all.each { |c| c.hide = ( c.state == 'hidden' ); c.save! }
|
||||
remove_column :contexts, :state
|
||||
end
|
||||
end
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue