fixed a bug with validation
This commit is contained in:
parent
2f8caa8740
commit
72542dc876
|
@ -2,7 +2,7 @@
|
|||
|
||||
Gem::Specification.new do |s|
|
||||
s.name = %q{couchrest}
|
||||
s.version = "0.14.1"
|
||||
s.version = "0.14.2"
|
||||
|
||||
s.required_rubygems_version = Gem::Requirement.new(">= 0") if s.respond_to? :required_rubygems_version=
|
||||
s.authors = ["J. Chris Anderson", "Matt Aimonetti"]
|
||||
|
|
|
@ -27,7 +27,7 @@ require 'couchrest/monkeypatches'
|
|||
|
||||
# = CouchDB, close to the metal
|
||||
module CouchRest
|
||||
VERSION = '0.14.1'
|
||||
VERSION = '0.14.2'
|
||||
|
||||
autoload :Server, 'couchrest/core/server'
|
||||
autoload :Database, 'couchrest/core/database'
|
||||
|
|
|
@ -52,10 +52,6 @@ module CouchRest
|
|||
return true if @options[:allow_nil] && field_value.nil?
|
||||
return false if !@options[:allow_nil] && field_value.nil?
|
||||
|
||||
if target.class.properties.has_property?(field_name)
|
||||
return true unless target.attribute_dirty?(field_name)
|
||||
end
|
||||
|
||||
confirm_value = target.instance_variable_get("@#{@confirm_field_name}")
|
||||
field_value == confirm_value
|
||||
end
|
||||
|
|
Loading…
Reference in a new issue