Skip to content

Commit

Permalink
Add Boolean#value_loaded? so it works wit the primitive validator
Browse files Browse the repository at this point in the history
  • Loading branch information
solnic committed Sep 12, 2011
1 parent 254102b commit b407d57
Showing 1 changed file with 6 additions and 0 deletions.
6 changes: 6 additions & 0 deletions lib/dm-core/property/boolean.rb
Expand Up @@ -6,8 +6,14 @@ class Boolean < Object

# @api semipublic
def value_dumped?(value)
value_loaded?(value)
end

# @api semipublic
def value_loaded?(value)
value == true || value == false
end

end # class Boolean
end # class Property
end # module DataMapper

0 comments on commit b407d57

Please sign in to comment.