Method: DataType::Base#dangerous_migration_from?

Defined in:
lib/dsl/data_type.rb

#dangerous_migration_from?(current_structure = nil) ⇒ Boolean

Returns:

  • (Boolean)


73
74
75
# File 'lib/dsl/data_type.rb', line 73

def dangerous_migration_from?(current_structure = nil)
  current_structure && (column[:type] != :text && [:string, :text].include?(current_structure[:type]) && column[:type] != current_structure[:type])
end