提交 d9f20c57 编写于 作者: C Carlos Antonio da Silva

Set hash value instead of using merge!

上级 f786469f
......@@ -104,7 +104,7 @@ def validates(*attributes)
raise ArgumentError, "You need to supply at least one attribute" if attributes.empty?
raise ArgumentError, "You need to supply at least one validation" if validations.empty?
defaults.merge!(:attributes => attributes)
defaults[:attributes] = attributes
validations.each do |key, options|
next unless options
......
Markdown is supported
0% .
You are about to add 0 people to the discussion. Proceed with caution.
先完成此消息的编辑!
想要评论请 注册