Isn't this expected behavior?"".to_i == 0.0 #=> true You are saying that assigning an empty string should nulify the value?
On Wed, Jan 14, 2009 at 02:17, stack <[email protected]> wrote: > > If a model has a decimal value which is currently set to 0.0 and the > field is blanked out with an empty string (like when submitting an > empty text_field for the value), the dirty objects code does not > recognize a change. > > > http://rails.lighthouseapp.com/projects/8994-ruby-on-rails/tickets/1754-setting-a-decimal-from-00-to-doesnt-constitute-a-change > > > > --~--~---------~--~----~------------~-------~--~----~ You received this message because you are subscribed to the Google Groups "Ruby on Rails: Core" group. To post to this group, send email to [email protected] To unsubscribe from this group, send email to [email protected] For more options, visit this group at http://groups.google.com/group/rubyonrails-core?hl=en -~----------~----~----~----~------~----~------~--~---
