Module: Switchman::ActiveRecord::Migration::Compatibility::V5_0

Defined in:
lib/switchman/active_record/migration.rb

Instance Method Summary collapse

Instance Method Details

#create_table(*args, **options) ⇒ Object



6
7
8
9
10
11
12
13
14
15
16
17
# File 'lib/switchman/active_record/migration.rb', line 6

def create_table(*args, **options)
  unless options.key?(:id)
    options[:id] = :bigserial
  end
  if block_given?
    super do |td|
      yield td
    end
  else
    super
  end
end