2017-12-15 20:55:52 -05:00
|
|
|
* Fix to working before/after validation callbacks on multiple contexts.
|
|
|
|
|
|
|
|
*Yoshiyuki Hirano*
|
|
|
|
|
2017-11-28 00:01:45 -05:00
|
|
|
## Rails 5.2.0.beta2 (November 28, 2017) ##
|
|
|
|
|
|
|
|
* No changes.
|
|
|
|
|
|
|
|
|
2017-11-27 13:01:15 -05:00
|
|
|
## Rails 5.2.0.beta1 (November 27, 2017) ##
|
|
|
|
|
2017-11-05 14:19:41 -05:00
|
|
|
* Execute `ConfirmationValidator` validation when `_confirmation`'s value is `false`.
|
|
|
|
|
|
|
|
*bogdanvlviv*
|
|
|
|
|
2017-09-21 09:39:49 -04:00
|
|
|
* Allow passing a Proc or Symbol to length validator options.
|
|
|
|
|
|
|
|
*Matt Rohrer*
|
|
|
|
|
2017-07-07 13:16:06 -04:00
|
|
|
* Add method `#merge!` for `ActiveModel::Errors`.
|
|
|
|
|
|
|
|
*Jahfer Husain*
|
|
|
|
|
2017-06-28 09:21:03 -04:00
|
|
|
* Fix regression in numericality validator when comparing Decimal and Float input
|
2017-05-27 09:47:07 -04:00
|
|
|
values with more scale than the schema.
|
|
|
|
|
|
|
|
*Bradley Priest*
|
|
|
|
|
2017-03-28 05:05:14 -04:00
|
|
|
* Fix methods `#keys`, `#values` in `ActiveModel::Errors`.
|
|
|
|
|
|
|
|
Change `#keys` to only return the keys that don't have empty messages.
|
|
|
|
|
|
|
|
Change `#values` to only return the not empty values.
|
|
|
|
|
2017-04-29 13:41:44 -04:00
|
|
|
Example:
|
|
|
|
|
|
|
|
# Before
|
|
|
|
person = Person.new
|
|
|
|
person.errors.keys # => []
|
|
|
|
person.errors.values # => []
|
|
|
|
person.errors.messages # => {}
|
|
|
|
person.errors[:name] # => []
|
|
|
|
person.errors.messages # => {:name => []}
|
|
|
|
person.errors.keys # => [:name]
|
|
|
|
person.errors.values # => [[]]
|
|
|
|
|
|
|
|
# After
|
|
|
|
person = Person.new
|
|
|
|
person.errors.keys # => []
|
|
|
|
person.errors.values # => []
|
|
|
|
person.errors.messages # => {}
|
|
|
|
person.errors[:name] # => []
|
|
|
|
person.errors.messages # => {:name => []}
|
|
|
|
person.errors.keys # => []
|
|
|
|
person.errors.values # => []
|
2017-03-28 05:05:14 -04:00
|
|
|
|
|
|
|
*bogdanvlviv*
|
|
|
|
|
2017-02-07 10:13:15 -05:00
|
|
|
|
2017-03-21 19:41:39 -04:00
|
|
|
Please check [5-1-stable](https://github.com/rails/rails/blob/5-1-stable/activemodel/CHANGELOG.md) for previous changes.
|