diff options
Diffstat (limited to 'activerecord/lib/active_record/connection_adapters/abstract_adapter.rb')
-rwxr-xr-x | activerecord/lib/active_record/connection_adapters/abstract_adapter.rb | 2 |
1 files changed, 1 insertions, 1 deletions
diff --git a/activerecord/lib/active_record/connection_adapters/abstract_adapter.rb b/activerecord/lib/active_record/connection_adapters/abstract_adapter.rb index ac58b60e8d..0ed496ea43 100755 --- a/activerecord/lib/active_record/connection_adapters/abstract_adapter.rb +++ b/activerecord/lib/active_record/connection_adapters/abstract_adapter.rb @@ -179,7 +179,7 @@ module ActiveRecord case type when :string then value when :text then value - when :integer then value.to_i + when :integer then value.to_i rescue value ? 1 : 0 when :float then value.to_f when :datetime then string_to_time(value) when :timestamp then string_to_time(value) |