Class: Decidim::DirectVerifications::AuthorizeUsersJob

Inherits:
BaseImportJob
  • Object
show all
Defined in:
app/jobs/decidim/direct_verifications/authorize_users_job.rb

Defined Under Namespace

Classes: NullSession

Instance Method Summary collapse

Methods inherited from BaseImportJob

#perform

Instance Method Details

#process_usersObject



10
11
12
13
14
15
16
17
18
19
20
21
22
23
# File 'app/jobs/decidim/direct_verifications/authorize_users_job.rb', line 10

def process_users
  Rails.logger.info "AuthorizeUsersJob: Authorizing #{emails.count} emails"
  emails.each do |email, data|
    Rails.logger.debug "AuthorizeUsersJob: Authorizing #{email}"
    AuthorizeUser.new(
      email,
      data,
      session,
      organization,
      instrumenter,
      authorization_handler
    ).call
  end
end

#typeObject



25
26
27
# File 'app/jobs/decidim/direct_verifications/authorize_users_job.rb', line 25

def type
  :authorized
end