Skip to content

Commit

Permalink
send doi string not object. #202
Browse files Browse the repository at this point in the history
  • Loading branch information
Martin Fenner committed Feb 9, 2019
1 parent fcad129 commit 00621fe
Show file tree
Hide file tree
Showing 3 changed files with 4 additions and 4 deletions.
4 changes: 2 additions & 2 deletions app/models/doi.rb
Original file line number Diff line number Diff line change
Expand Up @@ -680,7 +680,7 @@ def update_url
return nil if current_user.nil? || !is_registered_or_findable?

if %w(europ ethz).include?(provider_id) || %w(Crossref).include?(agency)
UrlJob.perform_later(self)
UrlJob.perform_later(doi)
else
HandleJob.perform_later(doi)
end
Expand Down Expand Up @@ -752,7 +752,7 @@ def self.delete_test_dois(from_date: nil)
end
end

# set minted date for DOIs that have been registered in an handle system (providers ETHZ and EUROP)
# set minted date for DOIs that have been registered in the handle system (providers ETHZ and EUROP)
def self.set_minted(from_date: nil)
from_date ||= Time.zone.now - 1.day
ids = ENV['HANDLES_MINTED'].to_s.split(",")
Expand Down
2 changes: 1 addition & 1 deletion config/initializers/_version.rb
Original file line number Diff line number Diff line change
@@ -1,5 +1,5 @@
module Lupo
class Application
VERSION = "2.3.24"
VERSION = "2.3.25"
end
end
2 changes: 1 addition & 1 deletion spec/jobs/url_job_spec.rb
Original file line number Diff line number Diff line change
Expand Up @@ -2,7 +2,7 @@

describe UrlJob, type: :job do
let(:doi) { create(:doi) }
subject(:job) { UrlJob.perform_later(doi) }
subject(:job) { UrlJob.perform_later(doi.doi) }

it 'queues the job' do
expect { job }.to have_enqueued_job(UrlJob)
Expand Down

0 comments on commit 00621fe

Please sign in to comment.