Class: Dscf::Banking::AccountCreationService

Inherits:
Object
  • Object
show all
Defined in:
app/services/dscf/banking/account_creation_service.rb

Class Method Summary collapse

Instance Method Summary collapse

Constructor Details

#initialize(application) ⇒ AccountCreationService

Returns a new instance of AccountCreationService.



7
8
9
# File 'app/services/dscf/banking/account_creation_service.rb', line 7

def initialize(application)
  @application = application
end

Class Method Details

.call(application) ⇒ Object



3
4
5
# File 'app/services/dscf/banking/account_creation_service.rb', line 3

def self.call(application)
  new(application).call
end

Instance Method Details

#callObject



11
12
13
14
15
16
17
18
19
# File 'app/services/dscf/banking/account_creation_service.rb', line 11

def call
  return nil unless @application.review_status == "approved"
  return nil if 

  
rescue => e
  Rails.logger.error "Account creation failed: #{e.message}" if defined?(Rails)
  nil
end