bolognese 0.9.29 → 0.9.30
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/Gemfile.lock +1 -1
- data/lib/bolognese/author_utils.rb +4 -2
- data/lib/bolognese/version.rb +1 -1
- metadata +1 -1
checksums.yaml
CHANGED
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
---
|
|
2
2
|
SHA1:
|
|
3
|
-
metadata.gz:
|
|
4
|
-
data.tar.gz:
|
|
3
|
+
metadata.gz: 9c2636bec6f6d7bf17b11575823249723fa55f1d
|
|
4
|
+
data.tar.gz: c5c872b49cb13b75d85020da182ae774719d74ad
|
|
5
5
|
SHA512:
|
|
6
|
-
metadata.gz:
|
|
7
|
-
data.tar.gz:
|
|
6
|
+
metadata.gz: 4c1d714a61f801b70ad744960398b29eb7666978a870f0f9c71deca488a24500bc93b6ed961a66acd835640e28c62db404a4dc208cf5a6b07dae28f1f61087f0
|
|
7
|
+
data.tar.gz: 289d0593d490273fcc8e3a403350f86625aff1d4d51fcd0b655590296060f0e9fb24c5992470afe9dc379b43cbf0e303ec9b0b17777e64416f551e1d13657679
|
data/Gemfile.lock
CHANGED
|
@@ -94,8 +94,10 @@ module Bolognese
|
|
|
94
94
|
# parse nameIdentifier from DataCite
|
|
95
95
|
def get_name_identifiers(author)
|
|
96
96
|
name_identifiers = Array.wrap(author.fetch("nameIdentifier", nil)).reduce([]) do |sum, n|
|
|
97
|
+
n = { "__content__" => n } if n.is_a?(String)
|
|
98
|
+
|
|
97
99
|
scheme = n.fetch("nameIdentifierScheme", nil)
|
|
98
|
-
scheme_uri = n.fetch("schemeURI", nil) || IDENTIFIER_SCHEME_URIS.fetch(scheme)
|
|
100
|
+
scheme_uri = n.fetch("schemeURI", nil) || IDENTIFIER_SCHEME_URIS.fetch(scheme, "https://orcid.org")
|
|
99
101
|
scheme_uri = "https://orcid.org/" if validate_orcid_scheme(scheme_uri)
|
|
100
102
|
scheme_uri << '/' unless scheme_uri.present? && scheme_uri.end_with?('/')
|
|
101
103
|
|
|
@@ -106,7 +108,7 @@ module Bolognese
|
|
|
106
108
|
identifier = identifier.gsub(" ", "-")
|
|
107
109
|
end
|
|
108
110
|
|
|
109
|
-
if identifier.present?
|
|
111
|
+
if identifier.present? && scheme_uri.present?
|
|
110
112
|
sum << scheme_uri + identifier
|
|
111
113
|
else
|
|
112
114
|
sum
|
data/lib/bolognese/version.rb
CHANGED