From 007c3d8bcb695c3a712b85eb882c95a940c8875e Mon Sep 17 00:00:00 2001 From: Francesco Rodriguez Date: Wed, 16 May 2012 00:03:03 -0500 Subject: better example format in validates_exclusion_of docs --- activemodel/lib/active_model/validations/exclusion.rb | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) (limited to 'activemodel/lib') diff --git a/activemodel/lib/active_model/validations/exclusion.rb b/activemodel/lib/active_model/validations/exclusion.rb index 5fedb1978b..310e07f897 100644 --- a/activemodel/lib/active_model/validations/exclusion.rb +++ b/activemodel/lib/active_model/validations/exclusion.rb @@ -1,7 +1,6 @@ require "active_model/validations/clusivity" module ActiveModel - # == Active Model Exclusion Validator module Validations class ExclusionValidator < EachValidator @@ -21,7 +20,8 @@ module ActiveModel # validates_exclusion_of :username, :in => %w( admin superuser ), :message => "You don't belong here" # validates_exclusion_of :age, :in => 30..60, :message => "This site is only for under 30 and over 60" # validates_exclusion_of :format, :in => %w( mov avi ), :message => "extension %{value} is not allowed" - # validates_exclusion_of :password, :in => lambda { |p| [p.username, p.first_name] }, :message => "should not be the same as your username or first name" + # validates_exclusion_of :password, :in => lambda { |p| [p.username, p.first_name] }, + # :message => "should not be the same as your username or first name" # end # # Configuration options: -- cgit v1.2.3