2020-01-28 04:09:06 -05:00
|
|
|
# frozen_string_literal: true
|
|
|
|
|
2020-02-19 13:09:10 -05:00
|
|
|
class GroupImportWorker # rubocop:disable Scalability/IdempotentWorker
|
2020-01-28 04:09:06 -05:00
|
|
|
include ApplicationWorker
|
|
|
|
include ExceptionBacktrace
|
|
|
|
|
|
|
|
feature_category :importers
|
|
|
|
|
|
|
|
def perform(user_id, group_id)
|
|
|
|
current_user = User.find(user_id)
|
|
|
|
group = Group.find(group_id)
|
|
|
|
|
|
|
|
::Groups::ImportExport::ImportService.new(group: group, user: current_user).execute
|
|
|
|
end
|
|
|
|
end
|