Skip to content

Commit

Permalink
fix client doi import method. #690
Browse files Browse the repository at this point in the history
  • Loading branch information
Martin Fenner committed Dec 21, 2020
1 parent 821ca76 commit ba06d80
Show file tree
Hide file tree
Showing 2 changed files with 3 additions and 3 deletions.
4 changes: 2 additions & 2 deletions app/jobs/doi_not_indexed_job.rb
Original file line number Diff line number Diff line change
Expand Up @@ -3,7 +3,7 @@
class DoiNotIndexedJob < ApplicationJob
queue_as :lupo_background

def perform(client_id, options = {})
Doi.import_by_client(client_id, options)
def perform(client_id, _options = {})
Doi.import_by_ids(model: "Client", client_id: client_id)
end
end
2 changes: 1 addition & 1 deletion app/models/client.rb
Original file line number Diff line number Diff line change
Expand Up @@ -719,7 +719,7 @@ def self.import_dois_not_indexed(query: nil)
# loop through repositories that have DOIs not indexed in Elasticsearch
table.each do |row|
Rails.logger.info "Started to import #{row["DOIs in Database"]} DOIs (#{row["DOIs missing"]} missing) for repository #{row["Repository ID"]}."
DoiNotIndexedJob.perform_later(row["Repository ID"], doi_count: row["DOIs in Database"], missing_count: row["DOIs missing"])
DoiNotIndexedJob.perform_later(model: "Client", client_id: row["Repository ID"])
end
end

Expand Down

0 comments on commit ba06d80

Please sign in to comment.