Class: Moov::Models::Components::PayoutRecipient

Inherits:
Object
  • Object
show all
Extended by:
T::Sig
Includes:
Crystalline::MetadataFields
Defined in:
lib/moov/models/components/payoutrecipient.rb

Overview

Specify the intended recipient of the payout. Either ‘email` or `phone` must be specified, but not both.

This information will be used to authenticate the end user when they follow the payment link.

Instance Method Summary collapse

Methods included from Crystalline::MetadataFields

#field, #fields, included, #marshal_single, #to_dict, #to_json

Constructor Details

#initialize(email: nil, phone: nil) ⇒ PayoutRecipient

Returns a new instance of PayoutRecipient.



24
25
26
27
# File 'lib/moov/models/components/payoutrecipient.rb', line 24

def initialize(email: nil, phone: nil)
  @email = email
  @phone = phone
end

Instance Method Details

#==(other) ⇒ Object



30
31
32
33
34
35
# File 'lib/moov/models/components/payoutrecipient.rb', line 30

def ==(other)
  return false unless other.is_a? self.class
  return false unless @email == other.email
  return false unless @phone == other.phone
  true
end