Class: Grape::API::Boolean

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

Class Method Summary collapse

Class Method Details

.build(val) ⇒ Object


6
7
8
9
10
# File 'lib/grape/validations/validators/coerce.rb', line 6

def self.build(val)
  return nil if val != true && val != false

  new
end