Class: Grape::Validations::ValidatorFactory

Inherits:
Object
  • Object
show all
Defined in:
lib/grape/validations/validator_factory.rb

Class Method Summary collapse

Class Method Details

.create_validator(options) ⇒ Object



6
7
8
9
10
11
12
# File 'lib/grape/validations/validator_factory.rb', line 6

def self.create_validator(options)
  options[:validator_class].new(options[:attributes],
                                options[:options],
                                options[:required],
                                options[:params_scope],
                                options[:opts])
end