pubid-core 1.3.0 → 1.4.0
Sign up to get free protection for your applications and to get access to all the features.
- checksums.yaml +4 -4
- data/lib/pubid/core/renderer/base.rb +10 -8
- data/lib/pubid/core/version.rb +1 -1
- metadata +2 -2
checksums.yaml
CHANGED
@@ -1,7 +1,7 @@
|
|
1
1
|
---
|
2
2
|
SHA256:
|
3
|
-
metadata.gz:
|
4
|
-
data.tar.gz:
|
3
|
+
metadata.gz: b1e2dbeb108d767054166d4fec9c0bb64e5c3a7ebb8811dc4f97de4c6cea4e93
|
4
|
+
data.tar.gz: 0aa8be27d6b839e6e985d8ce1a376d6fbe55ef07e87a664ac902c455e937c887
|
5
5
|
SHA512:
|
6
|
-
metadata.gz:
|
7
|
-
data.tar.gz:
|
6
|
+
metadata.gz: 06b053ef1516f1fbe0524171fbc27afd6659e301cabb6692fb46be8b746807f6e21e081c48bc10f8cb1be282607154a7f084850f117c62e3748f8e2de1b25922
|
7
|
+
data.tar.gz: d3f441ccc72743f752b81eb993c7c71088442c1c53376412553a809464473048a29e80503673962d6b496dd9efc1979ed191f35dea08d9f3f19032073bba3711
|
@@ -86,21 +86,23 @@ module Pubid::Core::Renderer
|
|
86
86
|
end
|
87
87
|
|
88
88
|
def render_base(params, prefix = "")
|
89
|
-
"%{publisher}
|
89
|
+
"%{publisher}#{prefix} %{number}" % params
|
90
90
|
end
|
91
91
|
|
92
92
|
def render_identifier(params)
|
93
93
|
render_base(params)
|
94
94
|
end
|
95
95
|
|
96
|
-
def
|
97
|
-
|
98
|
-
|
99
|
-
|
100
|
-
|
101
|
-
|
96
|
+
def render_publisher(publisher, _opts, params)
|
97
|
+
return publisher unless params[:copublisher]
|
98
|
+
|
99
|
+
case params[:copublisher]
|
100
|
+
when Array
|
101
|
+
([publisher] + params[:copublisher].map(&:to_s).sort.map(&:to_s)).map do |pub|
|
102
|
+
pub.gsub('-', '/')
|
103
|
+
end.join("/")
|
102
104
|
else
|
103
|
-
|
105
|
+
[publisher, params[:copublisher]].join("/")
|
104
106
|
end
|
105
107
|
end
|
106
108
|
|
data/lib/pubid/core/version.rb
CHANGED
metadata
CHANGED
@@ -1,14 +1,14 @@
|
|
1
1
|
--- !ruby/object:Gem::Specification
|
2
2
|
name: pubid-core
|
3
3
|
version: !ruby/object:Gem::Version
|
4
|
-
version: 1.
|
4
|
+
version: 1.4.0
|
5
5
|
platform: ruby
|
6
6
|
authors:
|
7
7
|
- Ribose Inc.
|
8
8
|
autorequire:
|
9
9
|
bindir: exe
|
10
10
|
cert_chain: []
|
11
|
-
date: 2022-11-
|
11
|
+
date: 2022-11-04 00:00:00.000000000 Z
|
12
12
|
dependencies:
|
13
13
|
- !ruby/object:Gem::Dependency
|
14
14
|
name: rake
|