commonmeta-ruby 3.4.0 → 3.4.1

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 CHANGED
@@ -1,7 +1,7 @@
1
1
  ---
2
2
  SHA256:
3
- metadata.gz: 75ab77371ac7823493a9e182a81284ae858bc10ee4d2a1df6dd598518024d645
4
- data.tar.gz: 696bccaa9835c5b5f7eefc666051fae1d01b608a4e94286b54630053324779b3
3
+ metadata.gz: c91a3a99a9a4bce161f2e63ca8971442fed3c53a98ab9dbd4073092e2dab1c1f
4
+ data.tar.gz: f8d2c449518738e304ac9ac86c366b2e3f69fad38b689dac34f1d090419ac747
5
5
  SHA512:
6
- metadata.gz: 6f21095312741ed18d18285ca29c836e1dc528dad317ce501beed5413407ce5d4436660298d9b593eda126e6814b45e0154bd10ec7c8f6e2c4f61794c7e097e7
7
- data.tar.gz: 7887477aee2ae90f7a8c271be662ae35bf72c82b69df4afcf41e74ded776c8a96bfbc5af4d04839400cdf57151467b69451e5c5d740ea487b194f2b00bb42984
6
+ metadata.gz: ce03a853f5e29dc3e31622abc95b3c5aff8a47605ad0f043df4ed624412dbda9114437b69a6dc3a2ef996a0080a13c32144cd5d069e9dd11d8658bb2ce57a6ce
7
+ data.tar.gz: 8a691b866c8590be9717f56a6b519edf3bef45e85cf7c4768b7a7d3305bf47b4e08233732854fb2c45772b114a1f77585cae6730ca19e666ee765274bda2d6b1
data/Gemfile.lock CHANGED
@@ -1,7 +1,7 @@
1
1
  PATH
2
2
  remote: .
3
3
  specs:
4
- commonmeta-ruby (3.4.0)
4
+ commonmeta-ruby (3.4.1)
5
5
  activesupport (>= 4.2.5, < 8.0)
6
6
  addressable (~> 2.8.1, < 2.8.2)
7
7
  base32-url (>= 0.7.0, < 1)
@@ -205,14 +205,16 @@ module Commonmeta
205
205
  xml.program("xmlns" => "http://www.crossref.org/relations.xsd",
206
206
  "name" => "relations") do
207
207
  related_identifiers.each do |related_identifier|
208
- identifier_type = validate_doi(related_identifier["id"]) ? "doi" : "url"
209
- id = identifier_type == "doi" ? doi_from_url(related_identifier["id"]) : related_identifier["id"]
210
- attributes = {
211
- "relation_type" => related_identifier["type"].camelize(:lower),
212
- "identifier_type" => identifier_type,
213
- }.compact
214
-
215
- xml.intra_work_relation(id, attributes)
208
+ xml.related_item do
209
+ identifier_type = validate_doi(related_identifier["id"]) ? "doi" : "uri"
210
+ id = identifier_type == "doi" ? doi_from_url(related_identifier["id"]) : related_identifier["id"]
211
+ attributes = {
212
+ "relation_type" => related_identifier["type"].camelize(:lower),
213
+ "identifier_type" => identifier_type,
214
+ }.compact
215
+
216
+ xml.intra_work_relation(id, attributes)
217
+ end
216
218
  end
217
219
  end
218
220
  end
@@ -1,5 +1,5 @@
1
1
  # frozen_string_literal: true
2
2
 
3
3
  module Commonmeta
4
- VERSION = '3.4.0'
4
+ VERSION = '3.4.1'
5
5
  end
metadata CHANGED
@@ -1,7 +1,7 @@
1
1
  --- !ruby/object:Gem::Specification
2
2
  name: commonmeta-ruby
3
3
  version: !ruby/object:Gem::Version
4
- version: 3.4.0
4
+ version: 3.4.1
5
5
  platform: ruby
6
6
  authors:
7
7
  - Martin Fenner