rails-gdpr-export 2.0.0 → 2.0.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 +4 -4
- data/Gemfile.lock +1 -1
- data/lib/gdpr_exporter.rb +4 -2
- data/lib/gdpr_exporter/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: 0561e470109530d0a9362b52aa8479071cbe6384ba6b6af9511d71807eb85a14
|
|
4
|
+
data.tar.gz: f85add70556d1276d3b3b82918b9e1a201320e2d202588666b8697763ea43eb2
|
|
5
5
|
SHA512:
|
|
6
|
-
metadata.gz:
|
|
7
|
-
data.tar.gz:
|
|
6
|
+
metadata.gz: 0c79b48b95786e4e6630eb92cc59decd22c9a3aeef42e639f40d5bb3f5496ff17026edd770009709df618b4eb3c9d29247afe441cc10ee84e9725a83adba2e24
|
|
7
|
+
data.tar.gz: 0aa8bb5e8fc3f35966df69b309ac8c63a25fbecb6c3337582c093d4385ddfabb82abaef7149448a931e79f00740660a8dad0375071efc58ea2df5a73c7f99da3
|
data/Gemfile.lock
CHANGED
data/lib/gdpr_exporter.rb
CHANGED
|
@@ -57,11 +57,11 @@ module GdprExporter
|
|
|
57
57
|
end
|
|
58
58
|
|
|
59
59
|
unless hash_params.class == Hash
|
|
60
|
-
raise "Gdpr fields collection error: last argument must be a hash!"
|
|
60
|
+
raise ArgumentError.new("Gdpr fields collection error: last argument must be a hash!")
|
|
61
61
|
end
|
|
62
62
|
|
|
63
63
|
unless hash_params.key?(:user_id)
|
|
64
|
-
raise "Gdpr fields collection error: the field aliasing user_id is not declared for '#{self}'!"
|
|
64
|
+
raise ArgumentError.new("Gdpr fields collection error: the field aliasing user_id is not declared for '#{self}'!")
|
|
65
65
|
end
|
|
66
66
|
|
|
67
67
|
# Adds the eigen class to the set of classes eligible for gdpr data collection.
|
|
@@ -124,6 +124,8 @@ module GdprExporter
|
|
|
124
124
|
# as "<tablename> <field>" in gdpr_collect then to get its value
|
|
125
125
|
# do r.<tablename>.<field>
|
|
126
126
|
f_splitted.inject(r) { |result, method| result.send(method) }
|
|
127
|
+
elsif (f_splitted.size > 2)
|
|
128
|
+
raise ArgumentError.new("Field #{f} is made of more than 2 words!?")
|
|
127
129
|
else
|
|
128
130
|
# No association involved, simply retrieve the field value.
|
|
129
131
|
r.send(f)
|
metadata
CHANGED
|
@@ -1,14 +1,14 @@
|
|
|
1
1
|
--- !ruby/object:Gem::Specification
|
|
2
2
|
name: rails-gdpr-export
|
|
3
3
|
version: !ruby/object:Gem::Version
|
|
4
|
-
version: 2.0.
|
|
4
|
+
version: 2.0.1
|
|
5
5
|
platform: ruby
|
|
6
6
|
authors:
|
|
7
7
|
- Chrislain Razafimahefa
|
|
8
8
|
autorequire:
|
|
9
9
|
bindir: exe
|
|
10
10
|
cert_chain: []
|
|
11
|
-
date: 2018-05-
|
|
11
|
+
date: 2018-05-23 00:00:00.000000000 Z
|
|
12
12
|
dependencies:
|
|
13
13
|
- !ruby/object:Gem::Dependency
|
|
14
14
|
name: bundler
|