From 05857ec30e6e496ce01aa2e428abd0ab5fae2e92 Mon Sep 17 00:00:00 2001 From: Xavier Noria Date: Sun, 24 Feb 2013 20:37:05 +0100 Subject: did a pass over the AM changelog [ci skip] --- activemodel/CHANGELOG.md | 50 +++++++++++++++++++++++++++++++++--------------- 1 file changed, 35 insertions(+), 15 deletions(-) (limited to 'activemodel') diff --git a/activemodel/CHANGELOG.md b/activemodel/CHANGELOG.md index 09e6ede064..416922cb89 100644 --- a/activemodel/CHANGELOG.md +++ b/activemodel/CHANGELOG.md @@ -19,7 +19,7 @@ *Roberto Vasquez Angel* -* `[attribute]_changed?` now returns `false` after a call to `reset_[attribute]!` +* `[attribute]_changed?` now returns `false` after a call to `reset_[attribute]!`. *Renato Mascarenhas* @@ -27,9 +27,11 @@ *Rafael Mendonça França* -* Specify type of singular association during serialization *Steve Klabnik* +* Specify type of singular association during serialization. -* Fixed length validator to correctly handle nil values. Fixes #7180. + *Steve Klabnik* + +* Fixed length validator to correctly handle `nil`. Fixes #7180. *Michal Zima* @@ -53,24 +55,27 @@ *Guillermo Iguaran* -* Due to a change in builder, nil values and empty strings now generates +* Due to a change in builder, `nil` and empty strings now generate closed tags, so instead of this: - It generates this: + it generates this: *Carlos Antonio da Silva* -* Changed inclusion and exclusion validators to accept a symbol for `:in` option. +* Inclusion/exclusion validators accept a method name passed as a symbol to the + `:in` option. - This allows to use dynamic inclusion/exclusion values using methods, besides the current lambda/proc support. + This allows to use dynamic inclusion/exclusion values using methods, besides + the current lambda/proc support. *Gabriel Sobrinho* -* `AM::Validation#validates` ability to pass custom exception to `:strict` option. +* `ActiveModel::Validation#validates` ability to pass custom exception to the + `:strict` option. *Bogdan Gusiev* @@ -81,7 +86,7 @@ *Anthony Alberto* -* Changed `AM::Serializers::JSON.include_root_in_json' default value to false. +* Changed `ActiveModel::Serializers::JSON.include_root_in_json` default value to false. Now, AM Serializers and AR objects have the same default behaviour. Fixes #6578. class User < ActiveRecord::Base; end @@ -108,16 +113,31 @@ *Francesco Rodriguez* -* Passing false hash values to `validates` will no longer enable the corresponding validators *Steve Purcell* +* Passing false hash values to `validates` will no longer enable the corresponding validators. + + *Steve Purcell* + +* `ConfirmationValidator` error messages will attach to `:#{attribute}_confirmation` instead of `attribute`. + + *Brian Cardarella* + +* Added `ActiveModel::Model`, a mixin to make Ruby objects work with AP out of box. -* `ConfirmationValidator` error messages will attach to `:#{attribute}_confirmation` instead of `attribute` *Brian Cardarella* + *Guillermo Iguaran* + +* `AM::Errors#to_json`: support `:full_messages` parameter. + + *Bogdan Gusiev* -* Added ActiveModel::Model, a mixin to make Ruby objects work with AP out of box *Guillermo Iguaran* +* Trim down Active Model API by removing `valid?` and `errors.full_messages`. -* `AM::Errors#to_json`: support `:full_messages` parameter *Bogdan Gusiev* + *José Valim* -* Trim down Active Model API by removing `valid?` and `errors.full_messages` *José Valim* +* When `^` or `$` are used in the regular expression provided to `validates_format_of` + and the `:multiline` option is not set to true, an exception will be raised. This is + to prevent security vulnerabilities when using `validates_format_of`. The problem is + described in detail in the Rails security guide. -* When `^` or `$` are used in the regular expression provided to `validates_format_of` and the :multiline option is not set to true, an exception will be raised. This is to prevent security vulnerabilities when using `validates_format_of`. The problem is described in detail in the Rails security guide *Jan Berdajs + Egor Homakov* + *Jan Berdajs + Egor Homakov* Please check [3-2-stable](https://github.com/rails/rails/blob/3-2-stable/activemodel/CHANGELOG.md) for previous changes. -- cgit v1.2.3