Browse files

Set default value to ActiveModel::Validator initializer attribute

Makes it easier to test its objects.
  • Loading branch information...
1 parent 66c8740 commit d4f46ee4fd666f458098b144c1451ce361948b35 Irio Irineu Musskopf Junior committed Jan 9, 2013
Showing with 1 addition and 1 deletion.
  1. +1 −1 activemodel/lib/active_model/validator.rb
View
2 activemodel/lib/active_model/validator.rb
@@ -103,7 +103,7 @@ def self.kind
end
# Accepts options that will be made available through the +options+ reader.
- def initialize(options)
+ def initialize(options = {})
@options = options.freeze
end

0 comments on commit d4f46ee

Please sign in to comment.