-require 'migrate'
-
-class AddTextFormat < ActiveRecord::Migration
+class AddTextFormat < ActiveRecord::Migration[4.2]
def up
- create_enumeration :format_enum, %w(html markdown text)
+ create_enum :format_enum, %w[html markdown text]
add_column :users, :description_format, :format_enum, :null => false, :default => "html"
add_column :user_blocks, :reason_format, :format_enum, :null => false, :default => "html"
add_column :diary_entries, :body_format, :format_enum, :null => false, :default => "html"