Dry-validation messages formating


#1

Hello. I added some custom date predicates to my schemas.

module Leidang
  module Predicates
    include Dry::Logic::Predicates

    predicate(:after_or_equal_to?) do |value, current|
      current >= value
    end

    predicate(:before_or_equal_to?) do |value, current|
      value.present? ? current <= value : true
    end
  end
end

And now when I use them in my schemas I get the following message “must be before or equal to 2017-06-10” but I want “must be before or equal to 06/10/2017”