examples/each.rb in dry-validation-0.6.0 vs examples/each.rb in dry-validation-0.7.0

- old
+ new

@@ -1,15 +1,10 @@ +require 'byebug' require 'dry-validation' -class Schema < Dry::Validation::Schema - key(:phone_numbers) do |phone_numbers| - phone_numbers.array? do - phone_numbers.each(&:str?) - end - end +schema = Dry::Validation.Schema do + key(:phone_numbers).each(:str?) end - -schema = Schema.new errors = schema.call(phone_numbers: '').messages puts errors.inspect