Skip to content

Commit

Permalink
Pass account object to AS creation job
Browse files Browse the repository at this point in the history
Otherwise it is invoked outside of the tenant context.
  • Loading branch information
mjgiarlo committed Apr 27, 2017
1 parent b924ef5 commit 25c33b3
Show file tree
Hide file tree
Showing 2 changed files with 3 additions and 2 deletions.
2 changes: 1 addition & 1 deletion app/jobs/create_account_inline_job.rb
Original file line number Diff line number Diff line change
Expand Up @@ -3,6 +3,6 @@ def perform(account)
CreateSolrCollectionJob.perform_now(account)
CreateFcrepoEndpointJob.perform_now(account)
CreateRedisNamespaceJob.perform_now(account)
CreateDefaultAdminSetJob.perform_now
CreateDefaultAdminSetJob.perform_now(account)
end
end
3 changes: 2 additions & 1 deletion app/jobs/create_default_admin_set_job.rb
Original file line number Diff line number Diff line change
@@ -1,5 +1,6 @@
class CreateDefaultAdminSetJob < ActiveJob::Base
def perform
def perform(account)
AccountElevator.switch!(account.cname)
AdminSet.find_or_create_default_admin_set_id
end
end

0 comments on commit 25c33b3

Please sign in to comment.