gigo-activerecord 2.0.1 → 2.0.2
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/gemfiles/activerecord42.gemfile.lock +1 -1
- data/gemfiles/activerecord50.gemfile.lock +1 -1
- data/gemfiles/activerecord51.gemfile.lock +1 -1
- data/gemfiles/activerecord52.gemfile.lock +1 -1
- data/lib/gigo/active_record/base.rb +2 -3
- data/lib/gigo/active_record/version.rb +1 -1
- metadata +6 -7
checksums.yaml
CHANGED
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
---
|
|
2
2
|
SHA256:
|
|
3
|
-
metadata.gz:
|
|
4
|
-
data.tar.gz:
|
|
3
|
+
metadata.gz: a5e81e28ded94acf22d2e0c4c4d257391ea1d2bde45673f2954934036dadf042
|
|
4
|
+
data.tar.gz: 21843743f876d8f654c7c47b0c019441b976e3dc668a7f91e9bd61cc724a0035
|
|
5
5
|
SHA512:
|
|
6
|
-
metadata.gz:
|
|
7
|
-
data.tar.gz:
|
|
6
|
+
metadata.gz: d9fce3017845aa5d571824e91ef0e9a26ac9c1d29b0acc463878389e436eec5288c9cf671c71f614a6973a01bad42c694c6c90a9208978e6ffb569826008b06c
|
|
7
|
+
data.tar.gz: 976a524c208deb84cf3cd9b1afff4a616581149323a0c956ec356d255a7d6024a0690df61b526a7ff3ae7ef003e49eabf7a502611e26cd409970e4fba4d1c59c
|
|
@@ -54,7 +54,7 @@ module GIGO
|
|
|
54
54
|
Encoding.default_internal = GIGO.encoding
|
|
55
55
|
value = YAML.load(GIGO.load(yaml))
|
|
56
56
|
unless value.is_a?(klass)
|
|
57
|
-
raise SerializationTypeMismatch, "Attribute was supposed to be a #{klass.to_s}, but was a #{
|
|
57
|
+
raise ::ActiveRecord::SerializationTypeMismatch, "Attribute was supposed to be a #{klass.to_s}, but was a #{value.class}: #{value.inspect}"
|
|
58
58
|
end
|
|
59
59
|
value
|
|
60
60
|
ensure
|
|
@@ -64,7 +64,7 @@ module GIGO
|
|
|
64
64
|
def dump(value)
|
|
65
65
|
return klass.new.to_yaml if value.nil?
|
|
66
66
|
unless value.is_a?(klass)
|
|
67
|
-
raise SerializationTypeMismatch, "Attribute was supposed to be a #{klass.to_s}, but was a #{value.class}."
|
|
67
|
+
raise ::ActiveRecord::SerializationTypeMismatch, "Attribute was supposed to be a #{klass.to_s}, but was a #{value.class}: #{value.inspect}"
|
|
68
68
|
end
|
|
69
69
|
value.to_yaml
|
|
70
70
|
end
|
|
@@ -74,4 +74,3 @@ module GIGO
|
|
|
74
74
|
end
|
|
75
75
|
|
|
76
76
|
ActiveRecord::Base.extend GIGO::ActiveRecord::Base
|
|
77
|
-
|
metadata
CHANGED
|
@@ -1,14 +1,14 @@
|
|
|
1
1
|
--- !ruby/object:Gem::Specification
|
|
2
2
|
name: gigo-activerecord
|
|
3
3
|
version: !ruby/object:Gem::Version
|
|
4
|
-
version: 2.0.
|
|
4
|
+
version: 2.0.2
|
|
5
5
|
platform: ruby
|
|
6
6
|
authors:
|
|
7
7
|
- Ken Collins
|
|
8
|
-
autorequire:
|
|
8
|
+
autorequire:
|
|
9
9
|
bindir: bin
|
|
10
10
|
cert_chain: []
|
|
11
|
-
date:
|
|
11
|
+
date: 2022-02-03 00:00:00.000000000 Z
|
|
12
12
|
dependencies:
|
|
13
13
|
- !ruby/object:Gem::Dependency
|
|
14
14
|
name: gigo
|
|
@@ -127,7 +127,7 @@ homepage: http://github.com/customink/gigo-activerecord
|
|
|
127
127
|
licenses:
|
|
128
128
|
- MIT
|
|
129
129
|
metadata: {}
|
|
130
|
-
post_install_message:
|
|
130
|
+
post_install_message:
|
|
131
131
|
rdoc_options: []
|
|
132
132
|
require_paths:
|
|
133
133
|
- lib
|
|
@@ -142,9 +142,8 @@ required_rubygems_version: !ruby/object:Gem::Requirement
|
|
|
142
142
|
- !ruby/object:Gem::Version
|
|
143
143
|
version: '0'
|
|
144
144
|
requirements: []
|
|
145
|
-
|
|
146
|
-
|
|
147
|
-
signing_key:
|
|
145
|
+
rubygems_version: 3.3.6
|
|
146
|
+
signing_key:
|
|
148
147
|
specification_version: 4
|
|
149
148
|
summary: GIGO for ActiveRecord
|
|
150
149
|
test_files:
|