shreddies 0.6.0 → 0.7.0

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: 5d29eb71728861282bd3c4a7e04ee829c4d647962951dfc494b311146142a84b
4
- data.tar.gz: 9281b757f6ac85f5d17879b54b4554a7cf4ea5853c04420f52a4755080157092
3
+ metadata.gz: b512a5aaa15bead3897d186b72c0232b806d21ec1b884689e7fac2b1f6c7db7b
4
+ data.tar.gz: 45c0d21700671b9ecb9c0ef6a19d0c29c1e45172f9567513b12182a6819d7b55
5
5
  SHA512:
6
- metadata.gz: 70f1959dbd3cd6a7e134c3fb4404a8d75ea55e219ba8e01eaba675bcfbbdc597fc0e85a12df4574e73617cb5aec946f67fcb3a077d73ccbf068d5ec158e82996
7
- data.tar.gz: b8618164e87ad5d94279a5e9294ec7d975d2b96ec3966fe8b074f4733296b9c047348b718002942911442f9f4511a61909045baeccfb9d9705975c749ffa7fb7
6
+ metadata.gz: 5c4aa3c08206be63b44798b22a644220fc536506810ad756f7a73b913bf9e8fd23b8f94014b2b1c6e00eaa1d590473b9786ea6dbb8585e52f16d0b465c528f0b
7
+ data.tar.gz: fa170d48d3d9e4f512bc3fdc06de984fc4370af74ee69a5e01a112b9e0ffb80ef05b75f52f5a9b0feaec643677a90f442120984a4c4c3587481fcdafec7676e6
@@ -8,47 +8,47 @@ PATH
8
8
  GEM
9
9
  remote: https://rubygems.org/
10
10
  specs:
11
- actionpack (6.0.3.4)
12
- actionview (= 6.0.3.4)
13
- activesupport (= 6.0.3.4)
14
- rack (~> 2.0, >= 2.0.8)
11
+ actionpack (6.1.1)
12
+ actionview (= 6.1.1)
13
+ activesupport (= 6.1.1)
14
+ rack (~> 2.0, >= 2.0.9)
15
15
  rack-test (>= 0.6.3)
16
16
  rails-dom-testing (~> 2.0)
17
17
  rails-html-sanitizer (~> 1.0, >= 1.2.0)
18
- actionview (6.0.3.4)
19
- activesupport (= 6.0.3.4)
18
+ actionview (6.1.1)
19
+ activesupport (= 6.1.1)
20
20
  builder (~> 3.1)
21
21
  erubi (~> 1.4)
22
22
  rails-dom-testing (~> 2.0)
23
23
  rails-html-sanitizer (~> 1.1, >= 1.2.0)
24
- activemodel (6.0.3.4)
25
- activesupport (= 6.0.3.4)
26
- activerecord (6.0.3.4)
27
- activemodel (= 6.0.3.4)
28
- activesupport (= 6.0.3.4)
29
- activesupport (6.0.3.4)
24
+ activemodel (6.1.1)
25
+ activesupport (= 6.1.1)
26
+ activerecord (6.1.1)
27
+ activemodel (= 6.1.1)
28
+ activesupport (= 6.1.1)
29
+ activesupport (6.1.1)
30
30
  concurrent-ruby (~> 1.0, >= 1.0.2)
31
- i18n (>= 0.7, < 2)
32
- minitest (~> 5.1)
33
- tzinfo (~> 1.1)
34
- zeitwerk (~> 2.2, >= 2.2.2)
31
+ i18n (>= 1.6, < 2)
32
+ minitest (>= 5.1)
33
+ tzinfo (~> 2.0)
34
+ zeitwerk (~> 2.3)
35
35
  autotest-suffix (1.1.0)
36
36
  builder (3.2.4)
37
37
  combustion (1.3.1)
38
38
  activesupport (>= 3.0.0)
39
39
  railties (>= 3.0.0)
40
40
  thor (>= 0.14.6)
41
- concurrent-ruby (1.1.7)
41
+ concurrent-ruby (1.1.8)
42
42
  crass (1.0.6)
43
- erubi (1.9.0)
44
- i18n (1.8.5)
43
+ erubi (1.10.0)
44
+ i18n (1.8.7)
45
45
  concurrent-ruby (~> 1.0)
46
- loofah (2.7.0)
46
+ loofah (2.9.0)
47
47
  crass (~> 1.0.2)
48
48
  nokogiri (>= 1.5.9)
49
49
  method_source (1.0.0)
50
- mini_portile2 (2.4.0)
51
- minitest (5.14.2)
50
+ mini_portile2 (2.5.0)
51
+ minitest (5.14.3)
52
52
  minitest-autotest (1.1.1)
53
53
  minitest-server (~> 1.0)
54
54
  path_expander (~> 1.0)
@@ -56,9 +56,11 @@ GEM
56
56
  minitest (>= 4, < 6)
57
57
  minitest-server (1.0.6)
58
58
  minitest (~> 5.0)
59
- nokogiri (1.10.10)
60
- mini_portile2 (~> 2.4.0)
59
+ nokogiri (1.11.1)
60
+ mini_portile2 (~> 2.5.0)
61
+ racc (~> 1.4)
61
62
  path_expander (1.1.0)
63
+ racc (1.5.2)
62
64
  rack (2.2.3)
63
65
  rack-test (1.1.0)
64
66
  rack (>= 1.0, < 3)
@@ -67,19 +69,18 @@ GEM
67
69
  nokogiri (>= 1.6)
68
70
  rails-html-sanitizer (1.3.0)
69
71
  loofah (~> 2.3)
70
- railties (6.0.3.4)
71
- actionpack (= 6.0.3.4)
72
- activesupport (= 6.0.3.4)
72
+ railties (6.1.1)
73
+ actionpack (= 6.1.1)
74
+ activesupport (= 6.1.1)
73
75
  method_source
74
76
  rake (>= 0.8.7)
75
- thor (>= 0.20.3, < 2.0)
76
- rake (13.0.1)
77
+ thor (~> 1.0)
78
+ rake (13.0.3)
77
79
  sqlite3 (1.4.2)
78
- thor (1.0.1)
79
- thread_safe (0.3.6)
80
- tzinfo (1.2.8)
81
- thread_safe (~> 0.1)
82
- zeitwerk (2.4.1)
80
+ thor (1.1.0)
81
+ tzinfo (2.0.4)
82
+ concurrent-ruby (~> 1.0)
83
+ zeitwerk (2.4.2)
83
84
 
84
85
  PLATFORMS
85
86
  ruby
@@ -8,6 +8,8 @@ module Shreddies
8
8
 
9
9
  if serializer.is_a?(String) || serializer.is_a?(Symbol)
10
10
  serializer = serializer.to_s.safe_constantize
11
+ elsif serializer.is_a?(Proc)
12
+ return serializer.call
11
13
  end
12
14
 
13
15
  serializer ? serializer.render_as_json(self, options) : super
@@ -20,6 +22,8 @@ module Shreddies
20
22
 
21
23
  if serializer.is_a?(String) || serializer.is_a?(Symbol)
22
24
  serializer = serializer.to_s.safe_constantize
25
+ elsif serializer.is_a?(Proc)
26
+ return serializer.call
23
27
  end
24
28
 
25
29
  serializer ? serializer.render_as_json(self, options) : super
@@ -1,3 +1,3 @@
1
1
  module Shreddies
2
- VERSION = "0.6.0"
2
+ VERSION = "0.7.0"
3
3
  end
@@ -11,7 +11,7 @@ Gem::Specification.new do |spec|
11
11
  spec.summary = 'Stupid simple Rails model and object serializer'
12
12
  spec.homepage = 'https://github.com/joelmoss/shreddies'
13
13
  spec.license = 'MIT'
14
- spec.required_ruby_version = Gem::Requirement.new('>= 2.3.0')
14
+ spec.required_ruby_version = Gem::Requirement.new('>= 2.7.0')
15
15
 
16
16
  spec.metadata['homepage_uri'] = spec.homepage
17
17
  spec.metadata['source_code_uri'] = spec.homepage
metadata CHANGED
@@ -1,14 +1,14 @@
1
1
  --- !ruby/object:Gem::Specification
2
2
  name: shreddies
3
3
  version: !ruby/object:Gem::Version
4
- version: 0.6.0
4
+ version: 0.7.0
5
5
  platform: ruby
6
6
  authors:
7
7
  - Joel Moss
8
8
  autorequire:
9
9
  bindir: bin
10
10
  cert_chain: []
11
- date: 2020-11-11 00:00:00.000000000 Z
11
+ date: 2021-01-20 00:00:00.000000000 Z
12
12
  dependencies:
13
13
  - !ruby/object:Gem::Dependency
14
14
  name: activerecord
@@ -77,7 +77,7 @@ required_ruby_version: !ruby/object:Gem::Requirement
77
77
  requirements:
78
78
  - - ">="
79
79
  - !ruby/object:Gem::Version
80
- version: 2.3.0
80
+ version: 2.7.0
81
81
  required_rubygems_version: !ruby/object:Gem::Requirement
82
82
  requirements:
83
83
  - - ">="