Class: ActiveRecord::ConnectionAdapters::AbstractMysqlAdapter::MysqlString

Inherits:
Type::String
  • Object
show all
Defined in:
activerecord/lib/active_record/connection_adapters/abstract_mysql_adapter.rb

Overview

:nodoc:

Instance Method Summary collapse

Instance Method Details

#serialize(value) ⇒ Object


793
794
795
796
797
798
799
# File 'activerecord/lib/active_record/connection_adapters/abstract_mysql_adapter.rb', line 793

def serialize(value)
  case value
  when true then "1"
  when false then "0"
  else super
  end
end