diff options
author | Angelo capilleri <capilleri@yahoo.com> | 2012-06-08 10:09:28 +0200 |
---|---|---|
committer | Rafael Mendonça França <rafaelmfranca@gmail.com> | 2012-06-19 01:54:34 -0300 |
commit | b9ec47da00e7f5e159ff130441585c3b42e41849 (patch) | |
tree | 58908be96097647185a2659c588cfe81154f6053 /activerecord/README.rdoc | |
parent | 69f19b292ad4b228f2bc5f89732a8ef3b704fab6 (diff) | |
download | rails-b9ec47da00e7f5e159ff130441585c3b42e41849.tar.gz rails-b9ec47da00e7f5e159ff130441585c3b42e41849.tar.bz2 rails-b9ec47da00e7f5e159ff130441585c3b42e41849.zip |
Validates_numericality_of is skipped when changing 0 to to non-empty string
This happens when A has_many many B and A accepts_nested_attributes B that has a numeric colum
with initial 0 value. So a.update_attributes({:b_attributes => { :id => b.id, :numeric => 'foo' }})
passes the validation test but, the value of :numeric doesn't change.
his commit forces that the update fails with the above conditions.
Fixes #6393
Fixes #2331
Diffstat (limited to 'activerecord/README.rdoc')
0 files changed, 0 insertions, 0 deletions