]> git.openstreetmap.org Git - rails.git/blobdiff - db/migrate/20110521142405_rename_bugs_to_notes.rb
Merge remote-tracking branch 'upstream/pull/5296'
[rails.git] / db / migrate / 20110521142405_rename_bugs_to_notes.rb
index 44ca1f48413b90e5575ebc4f46a3b3054b279eec..2e90b5ce886899c58d40b132fe61dfeebfb49f65 100644 (file)
@@ -1,9 +1,7 @@
-require "migrate"
-
-class RenameBugsToNotes < ActiveRecord::Migration
+class RenameBugsToNotes < ActiveRecord::Migration[4.2]
   def self.up
   def self.up
-    rename_enumeration "map_bug_status_enum", "note_status_enum"
-    rename_enumeration "map_bug_event_enum", "note_event_enum"
+    rename_enum "map_bug_status_enum", :to => "note_status_enum"
+    rename_enum "map_bug_event_enum", :to => "note_event_enum"
 
     rename_table :map_bugs, :notes
     rename_index :notes, "map_bugs_changed_idx", "notes_updated_at_idx"
 
     rename_table :map_bugs, :notes
     rename_index :notes, "map_bugs_changed_idx", "notes_updated_at_idx"
@@ -25,7 +23,7 @@ class RenameBugsToNotes < ActiveRecord::Migration
     rename_index :notes, "notes_updated_at_idx", "map_bugs_changed_idx"
     rename_table :notes, :map_bugs
 
     rename_index :notes, "notes_updated_at_idx", "map_bugs_changed_idx"
     rename_table :notes, :map_bugs
 
-    rename_enumeration "note_event_enum", "map_bug_event_enum"
-    rename_enumeration "note_status_enum", "map_bug_status_enum"
+    rename_enum "note_event_enum", :to => "map_bug_event_enum"
+    rename_enum "note_status_enum", :to => "map_bug_status_enum"
   end
 end
   end
 end