Exception: ZohoHub::ValidationError

Inherits:
StandardError
  • Object
show all
Defined in:
lib/zoho_hub/with_validations.rb

Instance Attribute Summary collapse

Instance Method Summary collapse

Constructor Details

#initialize(record) ⇒ ValidationError

Returns a new instance of ValidationError.



59
60
61
62
63
64
# File 'lib/zoho_hub/with_validations.rb', line 59

def initialize(record)
  @record = record
  errors = @record.errors.join(', ')

  super(errors)
end

Instance Attribute Details

#recordObject (readonly)

Returns the value of attribute record.



57
58
59
# File 'lib/zoho_hub/with_validations.rb', line 57

def record
  @record
end