Sha256: 5ea5bd35991513ad475b237d6048b28a00a1d9de1d554a2b4336886121ef803a
Contents?: true
Size: 378 Bytes
Versions: 6
Compression:
Stored size: 378 Bytes
Contents
require 'dry/validation/schema' require 'dry/validation/input_type_compiler' module Dry module Validation class Schema::Form < Schema attr_reader :input_type def initialize super @input_type = InputTypeCompiler.new.(self.class.rules.map(&:to_ary)) end def call(input) super(input_type[input]) end end end end
Version data entries
6 entries across 6 versions & 1 rubygems