dor-services 5.26.1 → 5.26.2
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- checksums.yaml +4 -4
- data/lib/dor/services/suri_service.rb +7 -1
- data/lib/dor/version.rb +1 -1
- metadata +3 -3
checksums.yaml
CHANGED
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
---
|
|
2
2
|
SHA1:
|
|
3
|
-
metadata.gz:
|
|
4
|
-
data.tar.gz:
|
|
3
|
+
metadata.gz: 91ea97e67bf6ce3ae1992ac6c9d8cb6d3a9382fc
|
|
4
|
+
data.tar.gz: 173d380e4781c45fed253357148581cff442fe89
|
|
5
5
|
SHA512:
|
|
6
|
-
metadata.gz:
|
|
7
|
-
data.tar.gz:
|
|
6
|
+
metadata.gz: df1cafcecd2945f1c834ee0ce0ef306ad73ecbb414cb168bf2c1c74938867230b54c2b773e3f2b20fc9c06e5910a6def74676a23982d521a04740c4fd8c5bfa6
|
|
7
|
+
data.tar.gz: 6397e97f65f54111621d4b7ea2fdf83a74ee84581070f6b7a04ba5604c080d4a690d539f6bae5904ee76947e48f6b8987bca2b63a2bcb0c68f6db6fa306dd608
|
|
@@ -17,8 +17,14 @@ module Dor
|
|
|
17
17
|
ids = resource["identifiers?quantity=#{quantity}"].post('').chomp.split(/\n/).collect { |id| "#{Config.suri.id_namespace}:#{id.strip}" }
|
|
18
18
|
else
|
|
19
19
|
repo = ActiveFedora::Base.respond_to?(:connection_for_pid) ? ActiveFedora::Base.connection_for_pid(0) : ActiveFedora.fedora.connection
|
|
20
|
-
resp = Nokogiri::XML(repo.next_pid(numPIDs: quantity))
|
|
20
|
+
resp = Nokogiri::XML(repo.api.next_pid(numPIDs: quantity))
|
|
21
21
|
ids = resp.xpath('/pidList/pid').collect { |node| node.text }
|
|
22
|
+
# With modernish (circa 2015/6) dependencies, including Nokogiri and
|
|
23
|
+
# ActiveFedora/Rubydora, `ids` is `[]` above. If that is the case, try
|
|
24
|
+
# the XPath that works (confirmed with most recent `hydra_etd` work)
|
|
25
|
+
if ids.empty? && resp.root.namespaces.any?
|
|
26
|
+
ids = resp.xpath('/xmlns:pidList/xmlns:pid').collect { |node| node.text }
|
|
27
|
+
end
|
|
22
28
|
end
|
|
23
29
|
want_array ? ids : ids.first
|
|
24
30
|
|
data/lib/dor/version.rb
CHANGED
metadata
CHANGED
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
--- !ruby/object:Gem::Specification
|
|
2
2
|
name: dor-services
|
|
3
3
|
version: !ruby/object:Gem::Version
|
|
4
|
-
version: 5.26.
|
|
4
|
+
version: 5.26.2
|
|
5
5
|
platform: ruby
|
|
6
6
|
authors:
|
|
7
7
|
- Michael Klein
|
|
@@ -14,7 +14,7 @@ authors:
|
|
|
14
14
|
autorequire:
|
|
15
15
|
bindir: bin
|
|
16
16
|
cert_chain: []
|
|
17
|
-
date: 2018-
|
|
17
|
+
date: 2018-03-01 00:00:00.000000000 Z
|
|
18
18
|
dependencies:
|
|
19
19
|
- !ruby/object:Gem::Dependency
|
|
20
20
|
name: active-fedora
|
|
@@ -684,7 +684,7 @@ required_rubygems_version: !ruby/object:Gem::Requirement
|
|
|
684
684
|
version: 1.3.6
|
|
685
685
|
requirements: []
|
|
686
686
|
rubyforge_project:
|
|
687
|
-
rubygems_version: 2.6.
|
|
687
|
+
rubygems_version: 2.6.13
|
|
688
688
|
signing_key:
|
|
689
689
|
specification_version: 4
|
|
690
690
|
summary: Ruby implmentation of DOR services used by the SULAIR Digital Library
|