media_types-serialization 0.8.0 → 0.8.1

Sign up to get free protection for your applications and to get access to all the features.
checksums.yaml CHANGED
@@ -1,7 +1,7 @@
1
1
  ---
2
2
  SHA256:
3
- metadata.gz: 2041c208e2369bfd60399c0dce92cbea8f3e0c51c1c4b361c6c29540285eb95a
4
- data.tar.gz: 7cae4d020bc3c1b79665dc4cccb36701ed360190995f57c56eee7c0e715ce6e0
3
+ metadata.gz: d45613b95cbde04435ac48959dfce588a6a491e6e1fa4f2c617735b99f88dc53
4
+ data.tar.gz: 4bd26cf5cfd142d0fe6161730be139d5120da57575e2089c7decd9e729ee4f27
5
5
  SHA512:
6
- metadata.gz: 763a81b77ce760ad2634b4b8670286105ce017f205f9a1fc2b92d2f018af1512a15179bea3899f39c580c5b79207955e6dc869377eca1cf431c24bff7c410d74
7
- data.tar.gz: f255ce45bf62686fa789d309061030f23445fdbd68854cd7a9204c6e7ae4df701c8d7308b9b153e8ba95cd0287b44d0c9200c0d8df95869fc1329913f110d718
6
+ metadata.gz: 9c9f83c9556147082048657d63094af7512e05fb521ae93bfed8659ebe62aa53ea600c580fb11053ab1eab4eaba4f2e58659e491c31e23495049ca5adffd8343
7
+ data.tar.gz: 4da94ab9612d690c4b007e079a17fa69f39dc23e4b964c3df9024e6e6df52e81a5e3d4db116e3d7263ee909db00d801f860f9522267a797061d9548efaa54d88
data/CHANGELOG.md CHANGED
@@ -1,5 +1,9 @@
1
1
  # Changelog
2
2
 
3
+ ## 0.8.1
4
+
5
+ - 🐛 Fix collection wrappers sometimes sending the wrong data to serializers
6
+
3
7
  ## 0.8.0
4
8
 
5
9
  - ✨ Add support for having multiple link headers with the same `rel`
data/Gemfile.lock CHANGED
@@ -1,7 +1,7 @@
1
1
  PATH
2
2
  remote: .
3
3
  specs:
4
- media_types-serialization (0.7.0)
4
+ media_types-serialization (0.8.1)
5
5
  actionpack (>= 4.0.0)
6
6
  activesupport (>= 4.0.0)
7
7
  http_headers-accept (>= 0.2.2, < 1.0.0)
@@ -12,43 +12,43 @@ PATH
12
12
  GEM
13
13
  remote: https://rubygems.org/
14
14
  specs:
15
- actioncable (5.2.2)
16
- actionpack (= 5.2.2)
15
+ actioncable (5.2.4)
16
+ actionpack (= 5.2.4)
17
17
  nio4r (~> 2.0)
18
18
  websocket-driver (>= 0.6.1)
19
- actionmailer (5.2.2)
20
- actionpack (= 5.2.2)
21
- actionview (= 5.2.2)
22
- activejob (= 5.2.2)
19
+ actionmailer (5.2.4)
20
+ actionpack (= 5.2.4)
21
+ actionview (= 5.2.4)
22
+ activejob (= 5.2.4)
23
23
  mail (~> 2.5, >= 2.5.4)
24
24
  rails-dom-testing (~> 2.0)
25
- actionpack (5.2.2)
26
- actionview (= 5.2.2)
27
- activesupport (= 5.2.2)
25
+ actionpack (5.2.4)
26
+ actionview (= 5.2.4)
27
+ activesupport (= 5.2.4)
28
28
  rack (~> 2.0)
29
29
  rack-test (>= 0.6.3)
30
30
  rails-dom-testing (~> 2.0)
31
31
  rails-html-sanitizer (~> 1.0, >= 1.0.2)
32
- actionview (5.2.2)
33
- activesupport (= 5.2.2)
32
+ actionview (5.2.4)
33
+ activesupport (= 5.2.4)
34
34
  builder (~> 3.1)
35
35
  erubi (~> 1.4)
36
36
  rails-dom-testing (~> 2.0)
37
37
  rails-html-sanitizer (~> 1.0, >= 1.0.3)
38
- activejob (5.2.2)
39
- activesupport (= 5.2.2)
38
+ activejob (5.2.4)
39
+ activesupport (= 5.2.4)
40
40
  globalid (>= 0.3.6)
41
- activemodel (5.2.2)
42
- activesupport (= 5.2.2)
43
- activerecord (5.2.2)
44
- activemodel (= 5.2.2)
45
- activesupport (= 5.2.2)
41
+ activemodel (5.2.4)
42
+ activesupport (= 5.2.4)
43
+ activerecord (5.2.4)
44
+ activemodel (= 5.2.4)
45
+ activesupport (= 5.2.4)
46
46
  arel (>= 9.0)
47
- activestorage (5.2.2)
48
- actionpack (= 5.2.2)
49
- activerecord (= 5.2.2)
47
+ activestorage (5.2.4)
48
+ actionpack (= 5.2.4)
49
+ activerecord (= 5.2.4)
50
50
  marcel (~> 0.3.1)
51
- activesupport (5.2.2)
51
+ activesupport (5.2.4)
52
52
  concurrent-ruby (~> 1.0, >= 1.0.2)
53
53
  i18n (>= 0.7, < 2)
54
54
  minitest (~> 5.1)
@@ -56,9 +56,9 @@ GEM
56
56
  arel (9.0.0)
57
57
  awesome_print (1.8.0)
58
58
  builder (3.2.3)
59
- concurrent-ruby (1.1.4)
59
+ concurrent-ruby (1.1.5)
60
60
  crass (1.0.5)
61
- erubi (1.8.0)
61
+ erubi (1.9.0)
62
62
  globalid (0.4.2)
63
63
  activesupport (>= 4.2.0)
64
64
  http_headers-accept (0.2.2)
@@ -66,9 +66,9 @@ GEM
66
66
  http_headers-link (0.2.1)
67
67
  http_headers-utils (>= 0.2.0, < 1.0.0)
68
68
  http_headers-utils (0.2.0)
69
- i18n (1.6.0)
69
+ i18n (1.7.0)
70
70
  concurrent-ruby (~> 1.0)
71
- loofah (2.3.1)
71
+ loofah (2.4.0)
72
72
  crass (~> 1.0.2)
73
73
  nokogiri (>= 1.5.9)
74
74
  mail (2.7.1)
@@ -78,44 +78,44 @@ GEM
78
78
  media_types (0.6.2)
79
79
  method_source (0.9.2)
80
80
  mimemagic (0.3.3)
81
- mini_mime (1.0.1)
81
+ mini_mime (1.0.2)
82
82
  mini_portile2 (2.4.0)
83
- minitest (5.12.2)
84
- nio4r (2.3.1)
85
- nokogiri (1.10.4)
83
+ minitest (5.13.0)
84
+ nio4r (2.5.2)
85
+ nokogiri (1.10.7)
86
86
  mini_portile2 (~> 2.4.0)
87
- nokogiri (1.10.4-x64-mingw32)
87
+ nokogiri (1.10.7-x64-mingw32)
88
88
  mini_portile2 (~> 2.4.0)
89
- oj (3.9.2)
90
- rack (2.0.6)
89
+ oj (3.10.0)
90
+ rack (2.0.7)
91
91
  rack-test (1.1.0)
92
92
  rack (>= 1.0, < 3)
93
- rails (5.2.2)
94
- actioncable (= 5.2.2)
95
- actionmailer (= 5.2.2)
96
- actionpack (= 5.2.2)
97
- actionview (= 5.2.2)
98
- activejob (= 5.2.2)
99
- activemodel (= 5.2.2)
100
- activerecord (= 5.2.2)
101
- activestorage (= 5.2.2)
102
- activesupport (= 5.2.2)
93
+ rails (5.2.4)
94
+ actioncable (= 5.2.4)
95
+ actionmailer (= 5.2.4)
96
+ actionpack (= 5.2.4)
97
+ actionview (= 5.2.4)
98
+ activejob (= 5.2.4)
99
+ activemodel (= 5.2.4)
100
+ activerecord (= 5.2.4)
101
+ activestorage (= 5.2.4)
102
+ activesupport (= 5.2.4)
103
103
  bundler (>= 1.3.0)
104
- railties (= 5.2.2)
104
+ railties (= 5.2.4)
105
105
  sprockets-rails (>= 2.0.0)
106
106
  rails-dom-testing (2.0.3)
107
107
  activesupport (>= 4.2.0)
108
108
  nokogiri (>= 1.6)
109
- rails-html-sanitizer (1.0.4)
110
- loofah (~> 2.2, >= 2.2.2)
111
- railties (5.2.2)
112
- actionpack (= 5.2.2)
113
- activesupport (= 5.2.2)
109
+ rails-html-sanitizer (1.3.0)
110
+ loofah (~> 2.3)
111
+ railties (5.2.4)
112
+ actionpack (= 5.2.4)
113
+ activesupport (= 5.2.4)
114
114
  method_source
115
115
  rake (>= 0.8.7)
116
116
  thor (>= 0.19.0, < 2.0)
117
117
  rake (10.5.0)
118
- sprockets (3.7.2)
118
+ sprockets (4.0.0)
119
119
  concurrent-ruby (~> 1.0)
120
120
  rack (> 1, < 3)
121
121
  sprockets-rails (3.2.1)
@@ -126,9 +126,9 @@ GEM
126
126
  thread_safe (0.3.6)
127
127
  tzinfo (1.2.5)
128
128
  thread_safe (~> 0.1)
129
- websocket-driver (0.7.0)
129
+ websocket-driver (0.7.1)
130
130
  websocket-extensions (>= 0.1.0)
131
- websocket-extensions (0.1.3)
131
+ websocket-extensions (0.1.4)
132
132
 
133
133
  PLATFORMS
134
134
  ruby
@@ -1,5 +1,5 @@
1
1
  module MediaTypes
2
2
  module Serialization
3
- VERSION = '0.8.0'
3
+ VERSION = '0.8.1'.freeze
4
4
  end
5
5
  end
@@ -11,8 +11,10 @@ module MediaTypes
11
11
 
12
12
  delegate :to_json, to: :to_hash
13
13
  delegate :class, :set, :current_view, :current_media_type, to: :__getobj__
14
+ attr_accessor :inner_serializer
14
15
 
15
16
  def initialize(serializer)
17
+ self.inner_serializer = serializer.dup
16
18
  __setobj__ serializer
17
19
  end
18
20
 
@@ -45,7 +47,7 @@ module MediaTypes
45
47
  end
46
48
 
47
49
  def item_hash(item)
48
- __getobj__.instance_exec do
50
+ inner_serializer.instance_exec do
49
51
  set(item).to_hash
50
52
  end
51
53
  end
@@ -11,8 +11,10 @@ module MediaTypes
11
11
 
12
12
  delegate :to_json, to: :to_hash
13
13
  delegate :class, :set, :current_view, :current_media_type, to: :__getobj__
14
+ attr_accessor :inner_serializer
14
15
 
15
16
  def initialize(serializer)
17
+ self.inner_serializer = serializer.dup
16
18
  __setobj__ serializer
17
19
  end
18
20
 
@@ -40,7 +42,7 @@ module MediaTypes
40
42
  end
41
43
 
42
44
  def item_hash(item)
43
- __getobj__.instance_exec do
45
+ inner_serializer.instance_exec do
44
46
  set(item).send(:extract_self)
45
47
  end
46
48
  end
metadata CHANGED
@@ -1,14 +1,14 @@
1
1
  --- !ruby/object:Gem::Specification
2
2
  name: media_types-serialization
3
3
  version: !ruby/object:Gem::Version
4
- version: 0.8.0
4
+ version: 0.8.1
5
5
  platform: ruby
6
6
  authors:
7
7
  - Derk-Jan Karrenbeld
8
8
  autorequire:
9
9
  bindir: exe
10
10
  cert_chain: []
11
- date: 2019-10-29 00:00:00.000000000 Z
11
+ date: 2019-12-10 00:00:00.000000000 Z
12
12
  dependencies:
13
13
  - !ruby/object:Gem::Dependency
14
14
  name: actionpack